tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Costin.Manola...@eng.sun.com
Subject Re: Cleanup: sessions
Date Fri, 07 Jan 2000 20:40:39 GMT
> Is it necessary to pass the response here in order to create the session?  I
> was under the impression that the Request itself already knew which Response
> it was associated with, and you could therefore follow the chain if you
> really needed to (for setting the cookie, for example).

Well, there is a reason to pass both - the method might affect the response,
and it is important to have this clear in the signature instead of having a
side effect.
Also, both Request and Response are available - I see no reason to add an
extra request.getResponse() ( that will be needed since response is allways
used to create a new session)

> >
> >     public void accessed(HttpSession session);
>
> This updates the "last accessed time" value, right?

Yes.


Also note that a SessionManager needs to use the public methods in
Request/Response.

If you need more - you can make more methods public, but with a lot of care
as this will affect the interfaces we'll put on Request/Response.

Costin


Mime
View raw message