Hello,
I'm trying to implement a client with Axis for a web service implemented
with XFire. I generate service stubs with any problem and I can login
and call most of the web services but I'm having problems with those
that use XFire cookie based session management.
I need to propagate a remote session id that comes as a cookie on the
HTTP Headers of the response of the login request.
I can access this session id by using the following code:
MimeHeaders headers = stub._getCall().getResponseMessage().getMimeHeaders();
String remoteSessionId = headers.getHeader("set-cookie")[0];
I don't like it but it works, the problem is I haven't found a way to
add this HTTP header to the next request.
I've tried:
MimeHeaders headers = ((Stub)
port)._getCall().getMessageContext().getRequestMessage().getMimeHeaders();
headers.setHeader("set-cookie", account.getRemoteSessionId());
But the stub creates and invokes the _call object and I can't add
headers to it without modifying the stub. I tried changing _getCall for
_createCall but this doesn't work.
Any help would be appreciated.
Thanks and best regards,
Marcos
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]