persistent or non persistent connection in testing web service
I have a webservice. I am creati开发者_运维技巧ng a test application to get response from this webservice. Added service reference to the web service application.
Logic in my test appplication is below.
for(int i=0;i<100;i++)
{
MyServiceSoapClient wsClient = new MyServiceSoapClient();
wsClient.Endpoint.Address = new EndpointAddress(serverAddress);
MyLoginResponse loginResp=wsClient.Login("X","X");
}
Just wanted to know whether I am making a persistent connection or a non persistent connection in this approach. Any help?
Test your webservice using curl. Pass curl the -v
(verbose) flag. If you see Connection: close
in the response header, your web service does not support persistent connections.
精彩评论