Kenneth,

> Sorry for the confusion. It's my "there is always a solution" mentality
> getting in the way.

It wasn't getting in the way...I wanted a solution too...I'm a programmer, I
know anything is possible...even if I have to change code <g>

> Unfortunately for your purposes I believe that everyone is using "lazy"
> garbage collection. I think that you will also find that the fact that the
> HttpSession has timed out may not be detected until the servers have some
> time to spare.

I may have found two potential options:

#1)  HttpSessionBindListener.

        I'm still using Tomcat v3.2.1, so this interface may still be supported.
It supports two methods, one called for when my object is added to a
Session, the other when it's being removed.  Seems to fit the bill.  There
is another Listener for later Servlet versions, but as you say, they seem a
little less guaranteed.

#2)  javax.lang.ref.Reference/ReferenceQueue.

        Let's me apply a "weak" reference to my object, giving me time to do stuff
with it just before it goes totally out of reference...kind cool.

I've not tried either of these yet, but they seem on the right track.

Thanks for your help.

-Chris


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to