On Sun January 17 2010 12:02:12 am sadh wrote:
> Hi
> 
> Iam relatively new to webservices.
> I have a webservice which needs to maintain a session with the client, is
> there any mechanism in CXF with which we can maintian a session. since
>  there might be clients from multiple platforms it would be of gr8 help if
>  can maintain these from the server side.
> thanx in advance

Well, JAX-WS does allow you to use the HTTP session on the server side to 
implement session specific things.   HOWEVER, by default, JAX-WS clients will 
NOT maintain a session cookie.   You need to explicitly turn on the 
MAINTAIN_SESSION flag on the clients to have it maintain the session.   I'm 
not sure about other client technologies on the other platforms.  They may or 
may not send the session cookies that would be required.

Without the session cookies or for other transports, you would need to 
implement the session stuff yourself.  Usually as a soap header.   The clients 
would need to pass the session token back and forth as an extra parameter or 
other way of dealing with the header.   Possibly a bit more work.

-- 
Daniel Kulp
[email protected]
http://www.dankulp.com/blog

Reply via email to