I have an existing (gsoap based) service, and I'm trying to write an axis2 client for it. However, I'm having some troubles with one asynchronous 'notification' part.
In particular, this service that offers a subscription to real time data: 1. client connects to it 2. client issues a one-way call to subscribe to xyz (subscribe) 3. then while on the same keep-alive connection the server issues one-way, server to client, notification (publish) responses as the respective data comes in 4. this goes on until the connection breaks or the client issues an unsubscribe call I'm having some problems with the notification/publish part. The wsdl file generated by gsoap gives both subscribe and publish as one-way requests from the client to the server. Obviously that's wrong; therefore I changed the one way description in the wsdl for publish from an operation with just an input sub-element, to one with just an output sub-element. Normally with the simple one-way or the request/response I can run the wsdl2java tool on the gsoap's wsdl, and then simply use the generated code something like: RequestObject req = new RequestObject(.....); ResponseObject res = getServiceStub().request(req); // or for the one-way's just: getServiceStub().request(req); However, I'm puzzled what do I do with the notification/publish interaction. The wsdl2java does seem to generate the code to handle the response content wise, but how do I get at it. In other terms, seems like the logical approach would be: SubscribeObject req = new SubscribeObject(...); getServiceStub().subscribe(req); while (....) { //something comparable to gsoap's soap_recv_ns__event(connection, data struct); PublishData data = getServiceStub().receivePublish(); doSomething(data); } But the concrete details seem fuzzy at best. If someone can help out with this, I'd greatly appreciate it. Thanks.