axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ricky Ho <r...@cisco.com>
Subject Re: MessageContext.setMaintainSession
Date Tue, 01 Oct 2002 17:04:47 GMT
I think your SOAP service is depending on the "cookie" mechanism as well as 
the HTTP transport.  And you also restricting the session variables to ONE 
client.  But no doubt this approach is the easiest.

I think a better approach is to have the message itself carry some data 
that maps into an existing service instances using some correlation mechanism.

Best regards,
Ricky

At 09:12 AM 10/1/2002 -0600, Grant Echols \(JanusLogix\) wrote:
>Alex,
>
>I've been playing with sessions all day and found what I really wanted 
>after a bit of muddling around. I realize that with "scope"="session" that 
>I'd be getting a new instance of my SOAP service and would therefore be 
>able to store local variables unique to the session, etc. However, this 
>isn't what I'd been trying to achieve. I was looking for something more 
>like the HttpSession concept in servlets and was able to achieve this with 
>the "scope"="application" and by having the Axis client and service call 
>the MessageContext.setMaintainSession(true). Then the server can use the 
>MessageContext.getSession() to retrieve the session for the particular 
>client. So far this is working the way I'd wanted. I hope that this is not 
>relying on an unexpected behavior in Axis.
>
>Thanks again for your help. Your explanations (especially about the client 
>enabling sessions) made a big difference.
>
>Grant
>----- Original Message -----
>From: <mailto:AVolanis@rsasecurity.com>Volanis, Alexander
>To: <mailto:'axis-user@xml.apache.org'>'axis-user@xml.apache.org'
>Sent: Monday, September 30, 2002 4:05 PM
>Subject: RE: MessageContext.setMaintainSession
>
>Grant,
>
>As the name implies "scope"="session" is the way to enable session 
>tracking in Axis services. It is really up to the client to maintain the 
>session by caching the HTTP cookies returned by the server. Most clients 
>would either do this by default or require a flag to enable it like Axis 
>clients do. As far as HTTP sessions go this is all you need to support them.
>
>Alex
>-----Original Message-----
>From: Grant Echols (JanusLogix) [mailto:gechols@januslogix.com]
>Sent: Friday, September 27, 2002 3:48 PM
>To: axis-user@xml.apache.org
>Subject: Re: MessageContext.setMaintainSession
>
>Alex,
>
>Thank you for your explanation. It has helped clear up some misconceptions 
>on my part.
>
>I gather from your comments and the doc that I cannot use 
>"scope"="Application" if I want to maintain session oriented information 
>for a SOAP client? Is this the extent of the session management in Axis?
>
>Thanks,
>
>Grant
>
>----- Original Message -----
>From: <mailto:AVolanis@rsasecurity.com>Volanis, Alexander
>To: <mailto:'axis-user@xml.apache.org'>'axis-user@xml.apache.org'
>Sent: Friday, September 27, 2002 8:48 AM
>Subject: RE: MessageContext.setMaintainSession
>
>The correct way to enable session management is in your deploy.wsdd file. 
>Add <parameter name="scope" value="Session"/> to your service deployment. 
>To get the desired effect your clients have to enable session management 
>as well. Use ((org.apache.axis.client.Stub) ws).setMaintainSession(true) 
>where "ws" is your service client instance returned by the ServiceLocator 
>class implementation in Axis client generated code terms.
>
>Alex
>-----Original Message-----
>From: Grant Echols (JanusLogix) [mailto:gechols@januslogix.com]
>Sent: Thursday, September 26, 2002 3:12 PM
>To: axis-user@xml.apache.org
>Subject: MessageContext.setMaintainSession
>
>I'm trying to understand the MessageContext session management and I'm 
>confused by what its supposed to do. On the first request from a client I 
>see that the session management is not turned on so I turn it on. On the 
>second request the session management is still not turned on. Is there 
>some other requirement I don't know about?
>
>Thanks,
>
>Grant
>

Mime
View raw message