You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@ws.apache.org by Bratislav Ljubisic <bl...@kunstenindustrie.com> on 2003/06/04 21:54:11 UTC
SOAP and session
Hi everybody,
I just wanted to ask is there any way of preserving session information,
like in servlets. What I had in mind is: I would like to have one SOAP
application (client) that will login on server, and when it does I would
like to preserve those information in session. Later, from that same
SOAP application (client) I would like to extract session object and use
it for validation purposes. Is that possible and how?
--
Bratislav Ljubisic
A: Bul.Arsenija Carnojevica 171/26
11000 Beograd
Srbija, Yugoslavia
P: +381 11 123 375
M: +381 63 8 505 594
F: Stichting Kunst en Industrie
E: bl@kunstenindustrie.com
gandalf@crossradio.org
olorin@infosky.net
gandalf@fon.fon.bg.ac.yu
W: www.fmmedia.co.yu
www.kunstenindustrie.com
I: 11412608
----------------
The first sign of maturity is the discovery that the volume knob also
turns to
the left.
Re: SOAP and session
Posted by Bratislav Ljubisic <bl...@kunstenindustrie.com>.
On Wed, 2003-06-04 at 22:10, Scott Nichol wrote:
> In Apache SOAP, the a SOAPHTTPConnection instance saves the cookies
> it receives from a response and sends them back in subsequent
> requests. Therefore, if you re-use a SOAPHTTPConnection instance
> across multiple calls, those calls will be part of the same session,
> assuming, of course, that session support is activated on the server
> and uses cookies.
>
> On the server, you can handle sessions completely transparently by
> giving services a scope of session. That means an instance of the
> service is created for each session, which means any state maintained
> by an instance will be the state for a single session.
> Alternatively, you can access servlet sessions from your service and
> store data in those, so that you can give your service a different
> scope, such as application scope in which a single instance will
> service all requests.
>
Ahm, and how to re-use SOAPHTTPConnection? And how to extract session
ID? In servlets it is so fairly easy :) but I am a bit new in this :)
--
Bratislav Ljubisic
A: Bul.Arsenija Carnojevica 171/26
11000 Beograd
Srbija, Yugoslavia
P: +381 11 123 375
M: +381 63 8 505 594
F: Stichting Kunst en Industrie
E: bl@kunstenindustrie.com
gandalf@crossradio.org
olorin@infosky.net
gandalf@fon.fon.bg.ac.yu
W: www.fmmedia.co.yu
www.kunstenindustrie.com
I: 11412608
----------------
WinNT error 003: FPU error - enter any 11 digit prime number to
continue.
Re: SOAP and session
Posted by Scott Nichol <sn...@scottnichol.com>.
In Apache SOAP, the a SOAPHTTPConnection instance saves the cookies
it receives from a response and sends them back in subsequent
requests. Therefore, if you re-use a SOAPHTTPConnection instance
across multiple calls, those calls will be part of the same session,
assuming, of course, that session support is activated on the server
and uses cookies.
On the server, you can handle sessions completely transparently by
giving services a scope of session. That means an instance of the
service is created for each session, which means any state maintained
by an instance will be the state for a single session.
Alternatively, you can access servlet sessions from your service and
store data in those, so that you can give your service a different
scope, such as application scope in which a single instance will
service all requests.
On 4 Jun 2003 at 21:54, Bratislav Ljubisic wrote:
> Hi everybody,
>
> I just wanted to ask is there any way of preserving session information,
> like in servlets. What I had in mind is: I would like to have one SOAP
> application (client) that will login on server, and when it does I would
> like to preserve those information in session. Later, from that same
> SOAP application (client) I would like to extract session object and use
> it for validation purposes. Is that possible and how?
>
> --
> Bratislav Ljubisic
> A: Bul.Arsenija Carnojevica 171/26
> 11000 Beograd
> Srbija, Yugoslavia
> P: +381 11 123 375
> M: +381 63 8 505 594
> F: Stichting Kunst en Industrie
> E: bl@kunstenindustrie.com
> gandalf@crossradio.org
> olorin@infosky.net
> gandalf@fon.fon.bg.ac.yu
> W: www.fmmedia.co.yu
> www.kunstenindustrie.com
> I: 11412608
> ----------------
> The first sign of maturity is the discovery that the volume knob also
> turns to
> the left.
>
>
Scott Nichol
Do not reply directly to this e-mail address,
as it is filtered to only receive e-mail from
specific mailing lists.