axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Eran Chinthaka (JIRA)" <j...@apache.org>
Subject [jira] Commented: (AXIS2-1061) sendReceiveNonBlocking fails to send multiple (identical) requests
Date Thu, 24 Aug 2006 06:47:40 GMT
    [ http://issues.apache.org/jira/browse/AXIS2-1061?page=comments#action_12430058 ] 
            
Eran Chinthaka commented on AXIS2-1061:
---------------------------------------

1. I didn't say if u use the same callback the invocations are synchronous. Please read carefully
what I've mentioned. What  I was trying to say is that, if you invoke using one callback and
if you are continuously checking callback.isComplete() == true, and then you invoke the second
one, then only you are wasting the power of non-blocking invocations. Non-blocking invocations
are such that you can invoke multiple times, independent of each other. 

2. Its not a matter of you waiting for sometime. Its a matter of OM object tree.

Just try this code to understand more. 

<code>
1.OMElement payload payload = getTestOMElement(); 
2.
3.OMFactory fac = OMAbstractFactory.getOMFactory();
4.OMElement parentOne = fac.createOMElement("ParentOne", null);
5.OMElement parentTwo = fac.createOMElement("ParentTwo", null);
6.
7.parentOne.addChild(payload);
8.parentTwo.addChild(payload);
9.
10.System.out.println(parentOne);
11.System.out.println(parentTwo);
</code>

What can you see? 

Then replace line #8 with the following and run the code.

parentTwo.addChild(parentTwo.cloneElement());

What can you see? Can you explain it?

Its the same thing that happens during your invocations.

> sendReceiveNonBlocking fails to send multiple (identical) requests
> ------------------------------------------------------------------
>
>                 Key: AXIS2-1061
>                 URL: http://issues.apache.org/jira/browse/AXIS2-1061
>             Project: Apache Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: client-api
>         Environment: Windows XP sp2, jdk 1.5.03, mac os X 10.4.7, jdk 1.5_06, axis2 17/08/06
>            Reporter: Michele Mazzucco
>            Priority: Critical
>
> The call sendReceiveNonBlocking call fails when multiple, identical messages are sent.
More in detail, the first send succeeds, but the second fails because the message is sent
with an empty SOAP body. A workaround is to interleave two consecutive send operations by
(at least) 600 ms (on my system).
> In other words:
> for (int i = 0; i < execution.requestNum; i++) {
> 	OMElement payload = getTestOMElement();
> 	sender.sendReceiveNonBlocking(payload, callback);
> }
> succeeds, while:
> OMElement payload payload = getTestOMElement();
> for (int i = 0; i < execution.requestNum; i++) {
> 	sender.sendReceiveNonBlocking(payload, callback);
> }
> fails, because (from the second send) the SOAP message is empty

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

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


Mime
View raw message