You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by lightbulb432 <ve...@hotmail.com> on 2007/06/17 22:27:50 UTC

Save sessions across restarts

During development, I'd like my sessions to stick around while I reload the
context or restart the container, so that when I make a change to a servlet,
for example, that requires a context reload, I don't have to relogin in the
application.

I notice the saveOnRestart attribute, which is supposed to be enabled by
default. Why is it that I must relogin every time? Do I need to make some
other change to the default server.xml or web.xml, which I haven't done?
(Haven't done anything with regards to "manager" or "store" configuration
elements.)

Thanks.
-- 
View this message in context: http://www.nabble.com/Save-sessions-across-restarts-tf3937140.html#a11166675
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Save sessions across restarts

Posted by Mark Thomas <ma...@apache.org>.
lightbulb432 wrote:
> I notice the saveOnRestart attribute, which is supposed to be enabled by
> default. Why is it that I must relogin every time?
Is your app being redeployed? What happens if you restart without
making any code changes?

Mark


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Save sessions across restarts

Posted by Mark Thomas <ma...@apache.org>.
Martin Gainty wrote:
> What you need is SingleSignOn capability
> I would suggest looking at JetSpeed..
> http://portals.apache.org/jetspeed-2/guides/guide-tomcat-sso-cross-context-j2-realm.html

No, he doesn't. The OP asked about session persistence across reload /
restart. This has nothing to do with SSO.

Mark

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re[2]: Save sessions across restarts

Posted by 吴熊敏 <xw...@ublearning.com>.
Hahaha!!agree with you !!


On Wed, 20 Jun 2007 12:51:08 +1200
Stephen Souness <so...@hotmail.com> wrote:

> Martin Gainty wrote:
> > playing around with sessions or cookies has no impact on ability to 
> > preserve one's capability or ability to establish role verification
> > if you dont know anything about jetspeed you need to stay quiet
> > 
> > In any event lets take this offline as you dont have a clue what SSO means
> > Bye
> > 
> 
> Ignorance is bliss.
> 
> If you don't know, don't send people on wild goose chases.
> 
> --
> Stephen
> 
> 
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org

----------------------------
吴熊敏 <xw...@ublearning.com>


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Save sessions across restarts

Posted by Stephen Souness <so...@hotmail.com>.
Martin Gainty wrote:
> playing around with sessions or cookies has no impact on ability to 
> preserve one's capability or ability to establish role verification
> if you dont know anything about jetspeed you need to stay quiet
> 
> In any event lets take this offline as you dont have a clue what SSO means
> Bye
> 

Ignorance is bliss.

If you don't know, don't send people on wild goose chases.

--
Stephen


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Save sessions across restarts

Posted by Martin Gainty <mg...@hotmail.com>.
playing around with sessions or cookies has no impact on ability to preserve 
one's capability or ability to establish role verification
if you dont know anything about jetspeed you need to stay quiet

In any event lets take this offline as you dont have a clue what SSO means
Bye

This email message and any files transmitted with it contain confidential
information intended only for the person(s) to whom this email message is
addressed.  If you have received this email message in error, please notify
the sender immediately by telephone or email and destroy the original
message without making a copy.  Thank you.

----- Original Message ----- 
From: "Len Popp" <le...@gmail.com>
To: "Tomcat Users List" <us...@tomcat.apache.org>; "Martin Gainty" 
<mg...@hotmail.com>
Sent: Sunday, June 17, 2007 5:14 PM
Subject: Re: Save sessions across restarts


> As usual, Martin, you're completely off base. This has nothing to do
> with single-sign-on.
>
> When you shut down Tomcat or a webapp, session data is written to the
> file SESSIONS.ser in work\Catalina\localhost\<x> where <x> is either
> "_" or the application name. I don't think you have to do anything
> special to enable this feature (someone correct me if I'm wrong) but
> it can fail. Check if the SESSIONS.ser file is being created, and if
> not check the log files for errors.
>
> If you are putting data into the session object using setAttribute,
> those objects must be serializable. Otherwise the sessions can't be
> saved.
> -- 
> Len
>
> On 6/17/07, Martin Gainty <mg...@hotmail.com> wrote:
>> What you need is SingleSignOn capability
>> I would suggest looking at JetSpeed..
>> http://portals.apache.org/jetspeed-2/guides/guide-tomcat-sso-cross-context-j2-realm.html
>>
>> M--
>> This email message and any files transmitted with it contain confidential
>> information intended only for the person(s) to whom this email message is
>> addressed.  If you have received this email message in error, please 
>> notify
>> the sender immediately by telephone or email and destroy the original
>> message without making a copy.  Thank you.
>>
>> ----- Original Message -----
>> From: "lightbulb432" <ve...@hotmail.com>
>> To: <us...@tomcat.apache.org>
>> Sent: Sunday, June 17, 2007 4:27 PM
>> Subject: Save sessions across restarts
>>
>>
>> >
>> > During development, I'd like my sessions to stick around while I reload
>> > the
>> > context or restart the container, so that when I make a change to a
>> > servlet,
>> > for example, that requires a context reload, I don't have to relogin in
>> > the
>> > application.
>> >
>> > I notice the saveOnRestart attribute, which is supposed to be enabled 
>> > by
>> > default. Why is it that I must relogin every time? Do I need to make 
>> > some
>> > other change to the default server.xml or web.xml, which I haven't 
>> > done?
>> > (Haven't done anything with regards to "manager" or "store" 
>> > configuration
>> > elements.)
>> >
>> > Thanks.
>> > --
>> > View this message in context:
>> > http://www.nabble.com/Save-sessions-across-restarts-tf3937140.html#a11166675
>> > Sent from the Tomcat - User mailing list archive at Nabble.com.
>> >
>> >
>> > ---------------------------------------------------------------------
>> > To start a new topic, e-mail: users@tomcat.apache.org
>> > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> > For additional commands, e-mail: users-help@tomcat.apache.org
>> >
>> >
>>
>>
>> ---------------------------------------------------------------------
>> To start a new topic, e-mail: users@tomcat.apache.org
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
> 


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Save sessions across restarts

Posted by Len Popp <le...@gmail.com>.
As usual, Martin, you're completely off base. This has nothing to do
with single-sign-on.

When you shut down Tomcat or a webapp, session data is written to the
file SESSIONS.ser in work\Catalina\localhost\<x> where <x> is either
"_" or the application name. I don't think you have to do anything
special to enable this feature (someone correct me if I'm wrong) but
it can fail. Check if the SESSIONS.ser file is being created, and if
not check the log files for errors.

If you are putting data into the session object using setAttribute,
those objects must be serializable. Otherwise the sessions can't be
saved.
-- 
Len

On 6/17/07, Martin Gainty <mg...@hotmail.com> wrote:
> What you need is SingleSignOn capability
> I would suggest looking at JetSpeed..
> http://portals.apache.org/jetspeed-2/guides/guide-tomcat-sso-cross-context-j2-realm.html
>
> M--
> This email message and any files transmitted with it contain confidential
> information intended only for the person(s) to whom this email message is
> addressed.  If you have received this email message in error, please notify
> the sender immediately by telephone or email and destroy the original
> message without making a copy.  Thank you.
>
> ----- Original Message -----
> From: "lightbulb432" <ve...@hotmail.com>
> To: <us...@tomcat.apache.org>
> Sent: Sunday, June 17, 2007 4:27 PM
> Subject: Save sessions across restarts
>
>
> >
> > During development, I'd like my sessions to stick around while I reload
> > the
> > context or restart the container, so that when I make a change to a
> > servlet,
> > for example, that requires a context reload, I don't have to relogin in
> > the
> > application.
> >
> > I notice the saveOnRestart attribute, which is supposed to be enabled by
> > default. Why is it that I must relogin every time? Do I need to make some
> > other change to the default server.xml or web.xml, which I haven't done?
> > (Haven't done anything with regards to "manager" or "store" configuration
> > elements.)
> >
> > Thanks.
> > --
> > View this message in context:
> > http://www.nabble.com/Save-sessions-across-restarts-tf3937140.html#a11166675
> > Sent from the Tomcat - User mailing list archive at Nabble.com.
> >
> >
> > ---------------------------------------------------------------------
> > To start a new topic, e-mail: users@tomcat.apache.org
> > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> > For additional commands, e-mail: users-help@tomcat.apache.org
> >
> >
>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Save sessions across restarts

Posted by Martin Gainty <mg...@hotmail.com>.
What you need is SingleSignOn capability
I would suggest looking at JetSpeed..
http://portals.apache.org/jetspeed-2/guides/guide-tomcat-sso-cross-context-j2-realm.html

M--
This email message and any files transmitted with it contain confidential
information intended only for the person(s) to whom this email message is
addressed.  If you have received this email message in error, please notify
the sender immediately by telephone or email and destroy the original
message without making a copy.  Thank you.

----- Original Message ----- 
From: "lightbulb432" <ve...@hotmail.com>
To: <us...@tomcat.apache.org>
Sent: Sunday, June 17, 2007 4:27 PM
Subject: Save sessions across restarts


>
> During development, I'd like my sessions to stick around while I reload 
> the
> context or restart the container, so that when I make a change to a 
> servlet,
> for example, that requires a context reload, I don't have to relogin in 
> the
> application.
>
> I notice the saveOnRestart attribute, which is supposed to be enabled by
> default. Why is it that I must relogin every time? Do I need to make some
> other change to the default server.xml or web.xml, which I haven't done?
> (Haven't done anything with regards to "manager" or "store" configuration
> elements.)
>
> Thanks.
> -- 
> View this message in context: 
> http://www.nabble.com/Save-sessions-across-restarts-tf3937140.html#a11166675
> Sent from the Tomcat - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
> 


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org