Sunday, October 26, 2008

Got time out exception while calling java web service from wcf

While i was trying to call java base webservice got time out exception. Later on i sloved that by stoping NagleAlgorithm.

ServicePointManager.Expect100Continue = false;
ServicePointManager.UseNagleAlgorithm = false;

ServiceClient sc=new ServiceClient ();

UseNagleAlgorithm = false before creating your service endpoint client else its not working.

The Nagle algorithm is used to reduce network traffic by buffering small packets of data and transmitting them as a single packet. This process is also referred to as "nagling"; it is widely used because it reduces the number of packets transmitted and lowers the overhead per packet.
more on...
http://msdn.microsoft.com/en-us/library/system.net.servicepointmanager.usenaglealgorithm.aspx

other blog and link regading this issue
http://basildoncoder.com/blog/2007/12/
http://support.microsoft.com/kb/810814

0 comments: