Thanks Deepal.
I found the info in the following way:
MessageContext cxt = MessageContext.getCurrentMessageContext();
org.apache.axis2.transport.http.TransportHeaders headers = (
org.apache.axis2.transport.http.TransportHeaders)cxt.getProperty(
MessageContext.TRANSPORT_HEADERS);
System.out.println("Message Context Transport Header Propertie Keys: " +
headers.keySet() +"\nvalues: "+headers.values());
The output is:
Message Context Transport Header Properties Keys: [host=localhost:8080,
user-agent=Axis2, transfer-encoding=chunked, content-type=text/xml;
charset=UTF-8, cookie=$Version=0;
JSESSIONID=FDE73A5E37F98D25033C1DEA7F89AEA9; $Path=/axis2,
soapaction="urn:login"]
values: [localhost:8080, Axis2, chunked, text/xml; charset=UTF-8,
$Version=0; JSESSIONID=FDE73A5E37F98D25033C1DEA7F89AEA9; $Path=/axis2,
"urn:login"]
Thanks,
-Bo
On 1/19/07, Deepal Jayasinghe <[EMAIL PROTECTED]> wrote:
Hi,
>
> I have set a service to transport session scope and the session
> context worked as expected. But when I try to get the session cookie
> id, it always returns null.
> MessageContext cxt = MessageContext.getCurrentMessageContext ();
> SessionContext session = cxt.getSessionContext();
> String cookieId = session.getCookieID();
>
> On the client side, I used the following code, it also always return
> null.
>
> stub._getServiceClient().getOptions().getProperty(
> org.apache.axis2.transport.
> http.HTTPConstants.COOKIE_STRING)
Try ;
Object cookieString = msgContext.getProperty(HTTPConstants.COOKIE_STRING);
>
> Can someone shed some lights on how to get the cookie?
>
> Thanks,
> -Bo
--
Thanks,
Deepal
"The highest tower is built one brick at a time"
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]