You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by shanmugampl <sh...@india.adventnet.com> on 2003/01/23 10:36:14 UTC

Having same session in SingleSignOn

Hi All,

    I am using tomcat4.1.18. I have enabled SingleSignOn in my tomcat 
and this functionality is working fine. The problem is, I have some 
values stored in session of application A and i want to access these 
information's in Application B. But as a new Session object is getting 
 created for every context, i am unable to fetch the values stored. Is 
there any way by which i can have the same session object for all my 
application while using SingleSignOn.

Thanks
Shanmugam.PL


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Having same session in SingleSignOn

Posted by "Craig R. McClanahan" <cr...@apache.org>.

On Thu, 23 Jan 2003, shanmugampl wrote:

> Date: Thu, 23 Jan 2003 15:06:14 +0530
> From: shanmugampl <sh...@india.adventnet.com>
> Reply-To: Tomcat Users List <to...@jakarta.apache.org>,
>      shanmugampl@india.adventnet.com
> To: Tomcat Users List <to...@jakarta.apache.org>
> Subject: Having same session in SingleSignOn
>
> Hi All,
>
>     I am using tomcat4.1.18. I have enabled SingleSignOn in my tomcat
> and this functionality is working fine. The problem is, I have some
> values stored in session of application A and i want to access these
> information's in Application B. But as a new Session object is getting
>  created for every context, i am unable to fetch the values stored. Is
> there any way by which i can have the same session object for all my
> application while using SingleSignOn.
>

The servlet spec requires that sessions be scoped per webapp, even in a
single sign on environment.  Even if you could share a session, it would
not work anyway, because the web apps each have their own class loaders
and therefore do not share classes.  All you would get is
ClassNotFoundException problems.

You can share things between webapps by using a database, or by putting a
class in shared/lib or common/lib and using a static variable there to
store the common stuff.

> Thanks
> Shanmugam.PL

Craig



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>