I have a web service I'm calling and upon investigation I see the creation of the client is taking about 0.5-1 second alone. This is using web reference .net 2.0.
SomeWS.SomeWSSoapClient client = new SomeWS.SomeWSSoapClient(); // takes 0.5-1 seconds
Is this normal? Is it fetching something from the service endpoint that I can stop?
I compared it to adding via a service reference and while the client takes a short time to instantiate (0.2 secs) the method call takes a lot longer and the overall time is longer.
What can I do to speed up the instantiate time? Which method should be quicker?
thanks a lot! Ash
Not sure if you have gotten an answer yet or not, but I believe it has something to do with the full scope of the web service, I have an application currently connected to another web service that takes 5-10 sec to instantiate because the WSDL is somewhere in the MB range. To work around this, I went through the work to send and receive the SOAP requests through raw XML and Web Client, sine I only use a fraction of what the WS offered.
If anyone else has a better idea, I'm all ears!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With