> -----Original Message----- > From: Pramod Nair [mailto:[EMAIL PROTECTED]] > Sent: Thursday, September 12, 2002 9:43 AM > To: Vikramjit Singh > Subject: Re: A decorator pattern for > javax.servlet.http.HttpSession with > Servlet 2.2 > > > Yepp. Thanx for the quick response, Vikram .. but, as I > mentioned, iPlanet > EWS 6.0 does not support anything above Servlets 2.2, and > thats how I came > to be stuck up in this jam.
Check out which version of servlet does you iplanet work with. I work with weblogic, and weblogic 6.1 supports both 2.2 and 2.3. Did not work with IPlanet. To make life simple and to overcome problem such as yours, in servlet 2.3 listeners were added. > > Thanx and rgds > > Pramod Nair > > ----- Original Message ----- > From: "Vikramjit Singh" <[EMAIL PROTECTED]> > To: "'Pramod Nair'" <[EMAIL PROTECTED]> > Sent: Thursday, September 12, 2002 11:00 AM > Subject: RE: A decorator pattern for > javax.servlet.http.HttpSession with > Servlet 2.2 > > > > > -----Original Message----- > > > From: Pramod Nair [mailto:[EMAIL PROTECTED]] > > > Sent: Thursday, September 12, 2002 9:34 AM > > > To: [EMAIL PROTECTED] > > > Subject: A decorator pattern for > javax.servlet.http.HttpSession with > > > Servlet 2.2 > > > > > > > > > I happen to be creating a web appplication conforming to > > > Servlets spec 2.2 > > > (IPlanet Entrprise Web Server 6.0) Within this application, I have > > > implemented the Decorator pattern to create a > > > SessionDecorator class. This > > > SessionDecorator class implements HttpSession and also wraps > > > an HttpSession > > > object. All HttpSession methods within this SessionDecorator > > > (as of now) > > > simply default to the wrapped HttpSession object. > > > > > > The basic idea behind the Decorator is to provide > additional services > > > (Persistence, fail-over support etc) transparently, later on. > > > > > > Unfortunately, in spec 2.2 there is no support for Session > > > lifecycle events > > > (specifically the HttpSessionListener interface), so there is > > > no way that my > > > Decorator can come to know about an invalidate() that the > > > container has > > > called upon the wrapped HttpSession object. > > > > > > My Q's are > > > > > > * Is there some way the decorator can find out about > > > invalidate() being > > > called upon the wrapped HttpSession ? > > > > You should check the servlet2.3. > > http://java.sun.com/products/servlet/2.3/javadoc > > > > > * Am I doing the whole thing wrong ? > > > > Life shall become very easy, if you implment the Listener > interface in > 2.3. > > And most of the things shall be corrected. > > The listener codes have been discussed many times, you > could check the > > archives. > > Check this link also > > > > http://www.onjava.com/pub/a/onjava/2001/04/12/listeners.html > > > > > > regards > > > Pramod Nair > > > > Vikram. > > > > > > ______________________________________________________________ > > > _____________ > > > To unsubscribe, send email to [EMAIL PROTECTED] and > > > include in the body > > > of the message "signoff SERVLET-INTEREST". > > > > > > Archives: > http://archives.java.sun.com/archives/servlet-interest.html > > > Resources: > > > http://java.sun.com/products/servlet/external-resources.html > > > LISTSERV Help: http://www.lsoft.com/manuals/user/user.html > > > > > > > ___________________________________________________________________________ To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff SERVLET-INTEREST". Archives: http://archives.java.sun.com/archives/servlet-interest.html Resources: http://java.sun.com/products/servlet/external-resources.html LISTSERV Help: http://www.lsoft.com/manuals/user/user.html