You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by "Eoghan O'Hare (Jira)" <ji...@apache.org> on 2021/08/16 16:33:00 UTC

[jira] [Comment Edited] (AXIS2-6009) ServiceClient::createClient intermittently under load blocks for 5 seconds

    [ https://issues.apache.org/jira/browse/AXIS2-6009?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17399831#comment-17399831 ] 

Eoghan O'Hare edited comment on AXIS2-6009 at 8/16/21, 4:32 PM:
----------------------------------------------------------------

Hi,

Still no luck getting this working.

I moved to httpclient-4.5.13 after your information.

The code is not using sender.sendReceive to send the web service. It is using auto generated stubs, so an OperationClient is created each time and execute is called on that to send the web service request. Also the web services are https.

From the stack trace the Exception that is thrown is a Null pointer exception as you can see in the previous comment. Looking at the axis2 code on github, it is coming from line 193 in CommonsHTTPTransportSender::invoke. It looks like that line is;
{quote}Parameter param = transportOut.getParameter(HTTPConstants.OMIT_SOAP_12_ACTION);
{quote}
The member transportOut on the CommonsHTTPTransportSender must be null somehow.

I have tried setting transportOut to an instance of HttpClient4 in both the MessageContext and the ServiceClient. As well as using axis2.xml with transport sender and receivers set with the HttpClient4 class.

See attached the axis2.xml that I am using now.

The axis2.xml is on the classpath and is being loaded by the code;
{quote}stub = new VPAppIntfServiceStub(ConfigurationContextFactory.createBasicConfigurationContext("axis2.xml"), webserviceCall);
{quote}
I proved that it is being loaded by putting a syntax error in the xml as a test. The error is displayed in the log file that I am outputting axis logs to.

Any ideas on how to debug this further? I am a little stuck at this stage and would appreciate any pointers.

Thanks,

Eoghan

[^axis2.xml]

 


was (Author: o'hare):
Hi,

Still no luck getting this working.

I moved to httpclient-4.5.13 after your information.

The code is not using sender.sendReceive to send the web service. It is using auto generated stubs, so an OperationClient is created each time and execute is called on that to send the web service request. Also the web services are https.

From the stack trace the Exception that is thrown is a Null pointer exception as you can see in the previous comment. Looking at the axis2 code on github, it is coming from line 193 in CommonsHTTPTransportSender::invoke. It looks like that line is;
{quote}Parameter param = transportOut.getParameter(HTTPConstants.OMIT_SOAP_12_ACTION);
{quote}
The member transportOut on the CommonsHTTPTransportSender must be null somehow.

I have tried setting transportOut to an instance of HttpClient4 in both the MessageContext and the ServiceClient. As well as using axis2.xml with transport sender and receivers set with the HttpClient4 class.

See attached the axis2.xml that I am using now.

Any ideas on how to debug this further? I am a little stuck at this stage and would appreciate any pointers.

Thanks,

Eoghan

[^axis2.xml]

 

> ServiceClient::createClient intermittently under load blocks for 5 seconds
> --------------------------------------------------------------------------
>
>                 Key: AXIS2-6009
>                 URL: https://issues.apache.org/jira/browse/AXIS2-6009
>             Project: Axis2
>          Issue Type: Bug
>    Affects Versions: 1.7.9
>            Reporter: Eoghan O'Hare
>            Priority: Major
>         Attachments: ExceptionStackTrace.txt, axis2.xml, axis2client.7z, axis2client_httpclient4.log
>
>
> Using the axis2-kernel-1.7.9.jar.
> Our application is using automatically generated WS stubs for asynchronous SOAP web services over https. 
> ServiceClient::createClient is called for every asynchronous web service request.
> Callbacks are registered using OperationClient::setCallback().
> The non blocking web service request is sent by the API OperationClient::execute(false). 
> The option isUseSeparateListener is set to false.
> The default number of http connections are created, this is two from looking at pcap traces.
> Under low load rates, 20 requests per second, 1000 total requests, intermittently the call to ServiceClient::createClient blocks the calling thread for 5 seconds. Seems to be just over 5 seconds every time it occurs (between 5000ms and 5030ms), so it sounds like some timeout.
> The blocking seems to occur when a response to a previous web service is received at a similar time.
> After the 5 second blocking, an Exception is thrown from axis2 to our applications error callback. Exception stack trace is attached.
> I have tried to enable axis2 logging on the client side however there was nothing obvious in it from my point of view. Attaching the log. In the log the 5 second delay is between;
> 06:47:50:574
> 06:47:55:579
> If you require additional logging to be enabled to debug please let me know.
> Or if you need any further information, please let me know.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@axis.apache.org
For additional commands, e-mail: java-dev-help@axis.apache.org