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

RE: destroy() not called in my servlet

From: lacall <lacall@micron.com>
Date: Thu, 22 Apr 1999 17:25:13 -0400 (EDT)
Message-ID: <B1272D4045CBD111A96E0020AFFBF32D03DB7CDB@ntxchange03.micron.com>
To: "'www-jigsaw@w3.org'" <www-jigsaw@w3.org>
Another thought on the same problem: I also noticed when running this under
a debugger that there was a large number (20 or more, when I quit running)
of servlet handler threads (I forget what they were called). When does
jigsaw decide to spawn a new thread to handle a servlet, creating a new
instance of the servlet class? When does it reuse an existing instance of
the servlet class and its handler thread?

I am running the latest jigsaw source as of this morning from CVS.

Thanks.

Luke Call
EDM Group
Micron Technology, Boise 

-----Original Message-----
From:	lacall 
Sent:	Thursday, April 22, 1999 3:10 PM
To:	'www-jigsaw@w3.org'
Subject:	destroy() not called in my servlet

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 
Received on Friday, 23 April 1999 03:54:36 GMT

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