You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-dev@xml.apache.org by Senthil Kumar P <se...@aztec.soft.net> on 2001/04/19 16:11:00 UTC

reg : session state management


hi  ,

       can u help me in providing information about session state management
in SOAP. SOAP uses http protocol for remote procedure calls.HTTP PROTOCOL IS
STATELESS .so , in case of multi request what  will happen?? . does soap
supports session state management? this is urgent need. can anybody help me
in this aspect.


Thanks in advance.
Regards,
senthil

Re: hastable/vector in a return object

Posted by Ashish Arvikar <as...@netforensics.com>.
Hi Scott,
Thanx for the little tap on my head... I completely missed out the critical part, I
don't have the setter method for it :-))
Ashish

Scott Nichol wrote:

> What are you using to [de]serialize the object?  If it is the BeanSerializer, is your
> hashtable a bean property (does it have getter/setter methods to get/set a Hashtable
> reference)?
>
> Scott
>
> ----- Original Message -----
> From: "Ashish Arvikar" <as...@netforensics.com>
> To: <so...@xml.apache.org>
> Sent: Monday, April 23, 2001 4:38 PM
> Subject: hastable/vector in a return object
>
> > > Hi,
> >
> > I have a object that along with a few Integer datatypes also contains a
> > Hashtable. When I receive the object at the client end, all the Integer values
> > are as expected, however the hashtable is empty. As such if I try to return a
> > Hashtable or a Vector alone, I am able to do it. Can any one please provide any
> > pointers.
> > Ashish
> >


Re: hastable/vector in a return object

Posted by Scott Nichol <sn...@computer.org>.
What are you using to [de]serialize the object?  If it is the BeanSerializer, is your
hashtable a bean property (does it have getter/setter methods to get/set a Hashtable
reference)?

Scott

----- Original Message -----
From: "Ashish Arvikar" <as...@netforensics.com>
To: <so...@xml.apache.org>
Sent: Monday, April 23, 2001 4:38 PM
Subject: hastable/vector in a return object


> > Hi,
>
> I have a object that along with a few Integer datatypes also contains a
> Hashtable. When I receive the object at the client end, all the Integer values
> are as expected, however the hashtable is empty. As such if I try to return a
> Hashtable or a Vector alone, I am able to do it. Can any one please provide any
> pointers.
> Ashish
>


hastable/vector in a return object

Posted by Ashish Arvikar <as...@netforensics.com>.
> Hi,

I have a object that along with a few Integer datatypes also contains a
Hashtable. When I receive the object at the client end, all the Integer values
are as expected, however the hashtable is empty. As such if I try to return a
Hashtable or a Vector alone, I am able to do it. Can any one please provide any
pointers.
Ashish


Re: reg : session state management

Posted by Sanjiva Weerawarana <sa...@watson.ibm.com>.
Or, you can use the code in CVS now .. there's a "maintainSession"
property on SOAPHTTPConnection which does something like this. You
must of course use the same SOAPHTTPConnection instance for all the
calls for this to work.

Sanjiva.

----- Original Message -----
From: "Andi Vajda" <av...@nanospace.com>
To: <so...@xml.apache.org>
Sent: Thursday, April 19, 2001 12:02 PM
Subject: Re: reg : session state management


>
>  In order to do session tracking with SOAP you need to write your own
client
>  cookie management by:
>
>   - watching for "Set-Cookie" headers after call.invoke(...) by iterating
over
>     the headers returned by call.getSOAPTransport().getHeaders() and
saving
>     these cookies (your session cookie is in there) for the next call.
>   - writing an extension to SOAPHTTPConnection and setting it on your call
>     object with call.setSOAPTrantort(). This new class should send these
>     cookies along by adding them to the headers table passed in the
>     SOAPHTTPConnection.send() method.
>
> Andi..
>
> On Thu, 19 Apr 2001, Senthil Kumar P wrote:
>
> >
> >
> > hi  ,
> >
> >        can u help me in providing information about session state
management
> > in SOAP. SOAP uses http protocol for remote procedure calls.HTTP
PROTOCOL IS
> > STATELESS .so , in case of multi request what  will happen?? . does soap
> > supports session state management? this is urgent need. can anybody help
me
> > in this aspect.
> >
> >
> > Thanks in advance.
> > Regards,
> > senthil
> >


Re: reg : session state management

Posted by Scott Nichol <sn...@computer.org>.
The nightly builds already have session tracking internally, which can be enabled via
SOAPHTTPConnection#setMaintainSession.  You can access the headers via
SOAPHTTPConnection#getHeaders.  As has be bemoaned elsewhere, there is no corresponding
SOAPHTTPConnection#setHeaders for you to set new headers.  However, and Set-Cookie and
Set-Cookie2 headers received from the server will be sent back to it if session
maintenance is enabled.

Scott

----- Original Message -----
From: "Andi Vajda" <av...@nanospace.com>
To: <so...@xml.apache.org>
Sent: Thursday, April 19, 2001 12:02 PM
Subject: Re: reg : session state management


>
>  In order to do session tracking with SOAP you need to write your own client
>  cookie management by:
>
>   - watching for "Set-Cookie" headers after call.invoke(...) by iterating over
>     the headers returned by call.getSOAPTransport().getHeaders() and saving
>     these cookies (your session cookie is in there) for the next call.
>   - writing an extension to SOAPHTTPConnection and setting it on your call
>     object with call.setSOAPTrantort(). This new class should send these
>     cookies along by adding them to the headers table passed in the
>     SOAPHTTPConnection.send() method.
>
> Andi..
>
> On Thu, 19 Apr 2001, Senthil Kumar P wrote:
>
> >
> >
> > hi  ,
> >
> >        can u help me in providing information about session state management
> > in SOAP. SOAP uses http protocol for remote procedure calls.HTTP PROTOCOL IS
> > STATELESS .so , in case of multi request what  will happen?? . does soap
> > supports session state management? this is urgent need. can anybody help me
> > in this aspect.
> >
> >
> > Thanks in advance.
> > Regards,
> > senthil
> >
>
>


Re: reg : session state management

Posted by Andi Vajda <av...@nanospace.com>.
 In order to do session tracking with SOAP you need to write your own client
 cookie management by:

  - watching for "Set-Cookie" headers after call.invoke(...) by iterating over
    the headers returned by call.getSOAPTransport().getHeaders() and saving
    these cookies (your session cookie is in there) for the next call.
  - writing an extension to SOAPHTTPConnection and setting it on your call
    object with call.setSOAPTrantort(). This new class should send these
    cookies along by adding them to the headers table passed in the
    SOAPHTTPConnection.send() method.

Andi..

On Thu, 19 Apr 2001, Senthil Kumar P wrote:

>
>
> hi  ,
>
>        can u help me in providing information about session state management
> in SOAP. SOAP uses http protocol for remote procedure calls.HTTP PROTOCOL IS
> STATELESS .so , in case of multi request what  will happen?? . does soap
> supports session state management? this is urgent need. can anybody help me
> in this aspect.
>
>
> Thanks in advance.
> Regards,
> senthil
>