PowerPlatform-DataverseServiceClient
PowerPlatform-DataverseServiceClient copied to clipboard
Why does WebProxyClient override Dispose to an empty method.
https://github.com/microsoft/PowerPlatform-DataverseServiceClient/blob/254952f3a781f1ab363c56f1a43c4d9b49652fed/src/GeneralTools/DataverseClient/Client/Connector/WebProxyClient.cs#L209
The WebProxyClient's Dispose method seems close over the ClientBase's dispose method, and also I call ServiceClient.Dispose every time, there are lots of HttpClient in HttpChannelFactory:
if your using .net core, The issue your seeing is (we believe) unrelated to the dispose method, We believe this is a quirk of the WCF implementation in .net core.
Could you give us a bit more information on your use case? how are you using the client?
thanks
We now create a connection pool of ServiceClient, there is a parent client with its clones, when the pool is ready to delete, we dispose the parent and clones
@MattB-msft https://docs.microsoft.com/en-us/dotnet/framework/wcf/samples/use-close-abort-release-wcf-client-resources WebProxyClient is derived from ClientBase, but I dont see the Close or Abort methods get called in the code. https://github.com/dotnet/wcf/blob/580ce66ac5def05f67186681595a9748f6bdf135/src/System.Private.ServiceModel/src/System/ServiceModel/ClientBase.cs#L407
@MattB-msft Could you help have a look at this issue, we are now using this sdk and will release at the end of this month, Thanks
We will look at optimizing that, however that code has been in production use across the Microsoft ecosystem since 2015 with very few reported issues of this type. There is some research going on regarding this and memory consumption patterns on our servers.
That said, You should be fine to use it now.
We are keeping this item open while we research it.
Thanks for the information, by the way, we use .net core, I don't know whether the implementation of WCF in .net core is different
Lots of things are different in .net core unfortunately (or fortunately depending on view point :) ) The .net core team has recently released the rollup of the WCF work they have been doing with us and others... we are talking them about this currently.