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

Arvind,

On 11/7/2009 11:35 PM, S Arvind wrote:
> is it possible to provide costume sessionid while creating session.? so that
> different time when session needs to be created i can create new sessionid
> and store it in cookie.

No, you can't customize the session id, but you can register a listener
that will be notified of session creation events:

http://tomcat.apache.org/tomcat-5.5-doc/servletapi/javax/servlet/http/HttpSessionListener.html

Note that there aren't any objects available during this method that
will let you set a cookie on the request. For that, you could write a
Filter that wraps the request to intercept calls to getSession() and
make sure that, if a session is created, your cookies are written as well.

I wish you'd tell us what the heck you're trying to do because I'm
certain there's an easier way to do it.

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

iEYEARECAAYFAkr4m2MACgkQ9CaO5/Lv0PCA+QCcCI3cfZTtJx9C4d1O/hvT+Rux
kLcAoLlTj04s7st0Sd4+B9rpx48TPVx8
=ZQDV
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to