axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yingchun cai <>
Subject how to correspond an async SOAP request and the response
Date Wed, 02 Feb 2011 06:23:02 GMT


I try to implement an async SOAP client request to a SOAP Server. But I need to 
get the response back and need to match the request.  I am using similar code 
like in the Non-Blocking example 
in I try to use 
the MessageId in the request and the RelatesTo fields in the response to match 
the request/response. However, I cannot find a way to get the RelatesTo field in 

the Response in the callback. Any idea what's the best way to do?


try {          org.apache.axis2.userguide.Axis2SampleDocLitServiceStub stub      

= new org.apache.axis2.userguide.Axis2SampleDocLitServiceStub(null,              

//implementing the callback online            
org.apache.axis2.userguide.Axis2SampleDocLitServiceCallbackHandler callback =    

new org.apache.axis2.userguide.Axis2SampleDocLitServiceCallbackHandler() {      

public void receiveResultechoString(                      
org.apache.axis2.userguide.xsd.EchoStringReturnDocument resDoc) {                

System.out.println(resDoc.getEchoStringReturn());                        }      

};         org.apache.axis2.userguide.xsd.EchoStringParamDocument reqDoc =      


reqDoc.setEchoStringParam("Axis2 Echo");            stub.startechoString(reqDoc, 

callback);         } catch (java.rmi.RemoteException e) {          
e.printStackTrace();        }


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message