-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Nelson,

Nelson D. guerrero wrote:
> On Wed, 2007-03-28 at 17:00 -0400, Christopher Schultz wrote:
> 
>> Assuming that Tomcat is managing your sessions (there aren't too many
>> good reasons to manage your own sessions), then Tomcat uses either
>> cookies or URL rewriting to maintain sessions between requests.
> 
> I'm sorry, I'm not following. By saying "managing your sessions", do you
> mean running tomcat standalone or letting tomcat manager the sessions
> and that the httpd uses the sessions off of the tomcat?

Apache httpd does not manage sessions at all, so it doesn't matter.

What I meant was "are you implementing your own strange session
management" -- and the answer is probably "no".

>> Probably not: Tomcat should do this for you already.
>>
>> Usually, sessions get lost because Tomcat has had to resort to URL
>> rewriting, but the application has not been written with this in mind.
>> For instance, every single URL that you generate ought to go through
>> request.encodeURL to make sure that the session id is properly added if
>> necessary. If you don't do this, then you'll end up creating a new
>> session when you use that (session-less) link.
> 
> Do they go through request.encodeURL automatically or do I have to do
> something?

Any time you generate a URL to be included in a web page, you need to
make sure that your URL goes through request.encodeURL. If you are using
a JSP tab library to build your links, then it is more than likely to do
this for you. To be on the safe side, tell us how you build your web
pages. If it's using JSP, then let us know about any tag libraries you
are using.

> Sorry for all the questions, I'm no developer and I'm surely not a
> tomcat administrator, they just shoved me the responsibility a couple of
> months ago and I've been learning ever since.

No problem. We tend to put the kid gloves on when someone starts asking
questions like this.

- -chris

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGCul79CaO5/Lv0PARAihuAJ4pngqkCAf3AKIC0AZjiyT5SCHgxQCgqAgT
0iMj8v32fwZo5uRQXikIE8U=
=g5ew
-----END PGP SIGNATURE-----

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

Reply via email to