Alexy

... note that calling ODE server is quite time consuming, each call takes from 20 to 40 seconds (maybe more)....

--- 1 - Downloaded Synapse 1.1 release, 3 ODE servers, 4 threads, 5 iterations. From time to time the following exception occur in client: 18:12:09,218 DEBUG HttpMethodDirector.executeWithRetry(403) : Closing the connection. 18:12:09,218 INFO HttpMethodDirector.executeWithRetry(438) : I/O exception (org.apache.commons.httpclient.NoHttpResponseException) caught when processing request: The server localhost failed to respond 18:12:09,234 DEBUG HttpMethodDirector.executeWithRetry(442) : The server localhost failed to respond org.apache.commons.httpclient.NoHttpResponseException: The server localhost failed to respond
This seems like a typical client connection timeout, as you say that a request takes 20~40 seconds to complete.. To overcome this you should increase your timeout.. for Synapse we use a default timeout of 60 seconds and easiest way to tune this is by setting a Java system property "http.socket.timeout" to the desired value in ms. For axis2 clients refer to this <http://wso2.org/library/230> (http://wso2.org/library/230)
--- 2 - Tried to deploy Synapse on Tomcat server, the same default configuration, I cannot even call one of servers, the first call returns exception:
Exception in thread "HttpClientWorker-1" java.lang.NullPointerException
....
at org.apache.synapse.transport.nhttp.HttpCoreNIOSender.sendUsingOutputStream(HttpCoreNIOSender.java:449)
This is a result of the above.. Since Synapse cannot send back the reply of the closed socket, it tries to get the OutputStream from the servlet.. which did not send this in the first place anyway..
--- 3 - Tried to call one of ODE servers directly from client, 3 threads, 5 iterations - all requests was successful, so it is not ODE issue.
This means probably the default Synapse timeout of 60 secs is the issue.. esp for the client side..
--- 4 - downloaded and compiled trunk release, set axis2 configuration option:
       <parameter name="requestTimeout">120000</parameter>
This will not work.. I assume you guessed this one :-) ? .. please use the system property I mentioned, or create a file nhttp.properties and put the values in there, and the file on the classpath
--- 4a - 3 ODE servers, 5 threads, 5 iterations: number of failed threads: 2 number of successive responses: 10 i.e. all threads which sent first 3 requests for first 3 servers succeeded, and other two - failed with error as described in --- 1 (user is already registered)

--- 4b - 2 ODE servers, 3 threads, 5 iterations: the same as --- 4a

--- 4c - 2 ODE servers, 2 threads, 5 iterations: everything SUCCESS

--- 5 - Tried to deploy Synapse 1.2-SNAPSHOT to Tomcat, got the same error as in --- 2
Not very relevant..
Somebody can tell me if I misconfigured something or this is Synapse specific issue?
Hope this helps.. let me know when u get over this..

asankha

Reply via email to