Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update HttpTransportBindingElement with Proxy property to enable client to specify IWebProxy #4563

Merged
merged 5 commits into from
Apr 15, 2021

Conversation

dimalyshev
Copy link
Contributor

Fix #4562

  • update HttpTransportBindingElement with Proxy property
  • update HttpChannelFactory to enable _proxy configuring with bindingElement.Proxy

this commit enables clients to configure binding with fully specified IWebProxy object:

  • address ,
  • credentials
  • etc.

fix dotnet#4561 Update HttpChannelFactory to use fully specified bindingElement.Proxy
@dnfadmin
Copy link

dnfadmin commented Mar 12, 2021

CLA assistant check
All CLA requirements met.

add Proxy property cloning
Add Proxy defaults
@dimalyshev dimalyshev changed the title Update HttpTransportBindingElement with Proxy property to enable client to specify IWebProxy #4562 Update HttpTransportBindingElement with Proxy property to enable client to specify IWebProxy Mar 14, 2021
@dimalyshev
Copy link
Contributor Author

@mconnew hi again! Sorry for annoying mentioning and pushing,
but have you managed to look it through ?

Thanx in advance for response!

@mconnew
Copy link
Member

mconnew commented Mar 22, 2021

This won't make the Proxy property available to you as it's not added to the contract (in src\System.ServiceModel.Http\ref\System.ServiceModel.Http.cs). But we have a general policy of not exposing new api in patch releases so I don't know how to easily solve this for you. Would accessing that property using reflection with the knowledge that it will be added to the public contract in the next major release work for you?

…ls/HttpChannelFactory.cs

Co-authored-by: Matt Connew <mconnew@microsoft.com>
@dimalyshev
Copy link
Contributor Author

Thank you for decision and proposal:
well, I'm not surely undestand using of Ref libraries built - as far as I understand the only aim to satisfy dependensies for other Ref libraries.
Anyway if produced libraries allow to set Proxy property - it is ok!
Let's build nuget? How long will it takes?

@mconnew
Copy link
Member

mconnew commented Mar 23, 2021

We have an implementation assembly/package (System.Private.ServiceModel) and contract packages (eg System.ServiceModel.Http). The contract package contains the reference assembly, this is the assembly you compile against. If the api isn't in the reference assembly, you can't use it in your code even if it's in the implementation assembly (System.Private.ServiceModel). We don't add new api's to contracts in patch releases which means you won't be able to compile against the api even if we ship an updated implementation assembly with it there. Which is why I was asking if you would be okay with using the api via reflection. Otherwise I'll need to look into seeing if an exception is possible.

@dimalyshev
Copy link
Contributor Author

dimalyshev commented Mar 24, 2021

I appreciate your explanation.
I have agreed recently to get nuget with this patch to be able to set Proxy property via reflection
until you'll be able to ship updated reference contract.
That's why I've asked - how long does it take to build nuget with patch and publish it to nuget.org?

@dimalyshev
Copy link
Contributor Author

Hello, @mconnew , what is news?
When nuget build shipping is expected

Thanx in advance...

@mconnew
Copy link
Member

mconnew commented Apr 15, 2021

@dimalyshev, this change will be released in a preview release as it's new API. We're still working out when that will be, but it won't be any later than the Build conference that's happening next month.

@mconnew mconnew merged commit b487139 into dotnet:main Apr 15, 2021
@dimalyshev dimalyshev deleted the patch-1 branch January 27, 2023 12:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

System.InvalidOperationException: The required UserNameSecurityToken was not provided
3 participants