Axis2 create persistent connection

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
Report Content as Inappropriate

Axis2 create persistent connection

I want to consume a webservice made in .NET. For generating my source code, I used Axis2 based on the WSDL of the web service. I launched Axis without options.

I can call the first method of the webservice. This is the authentification method "Connect" of the web service. After this, I call again a new method, but the webservice indicate that I'm not any more connected. The support of the web service told me it's because after I call the connect method, the connection is closed by java. And this, the webservice assume that I'm disconnected and close my session.

To solve this problem, my successif call of the both method should maintain the connection in live. However, I'm not sure that Axis2 suggest this functionalities, is it true?

How can I maintain connection between different calls?

Here is my java code :

WinbooksWebServiceStub stub = new WinbooksWebServiceStub("http://myUrl/Service.asmx");
Connect c = new Connect();

ConnectResponse resp = stub.connect(c);
ConnectParser connecterParser = new ConnectParser();//works and return the Token

HelloWorld h = new HelloWorld();
HelloWorldResponse Hresp = stub.helloWorld(h); //the result tell me that I'm not connected; connection lost