W3C home > Mailing lists > Public > www-jigsaw@w3.org > March to April 1999

Re: destroy() not called in my servlet

From: Benoit Mahe <Benoit.Mahe@sophia.inria.fr>
Date: Fri, 23 Apr 1999 10:18:29 +0200
Message-ID: <37202CD5.122679B5@sophia.inria.fr>
To: lacall <lacall@micron.com>
CC: "'www-jigsaw@w3.org'" <www-jigsaw@w3.org>
The destroy method is called at the end of the servlet timeout,
if the servlet class has been modified or when the server is killed.

The servlet timeout can be configured in the servlet properties or
per servlet (in the ServletWrapper).

Regards, Benoit.

lacall wrote:

> I have a servlet whose init() method starts a thread (a "cleanup thread")
> whose purpose is to watch over the threads created in doPost() and to stop
> them after a timeout period.  I found that I was running out of memory after
> running my servlet many times, and that this first thread (the "cleanup
> thread") seems to be the culprit--if I don't start() it, I don't have the
> memory leak.
>
> The solution I would think would be to stop that thread in the servlet's
> destroy() method. But I'm doing that; the destroy() method seems never to be
> called.
>
> Is there something I may be doing to prevent the destroy() method from
> getting called??
>
> Thanks.
>
> Luke Call
> EDM Group
> Micron Technology, Boise

--
- Benoît Mahé -------------------------------------------------------
                      World Wide Web Consortium   (W3C)
                    Architecture domain - Jigsaw Engineer

                http://www.w3.org/People/Mahe  - bmahe@w3.org
---------------------------------------------------------------------
Received on Friday, 23 April 1999 04:18:54 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 9 April 2012 12:13:29 GMT