Я использую Quartz для выполнения задания каждый час. Сервлет работает на Tomcat, и я использую ServletConextListener для прослушивания, когда контекст уничтожается.
Когда я закрываю tomcat, я получаю сообщение:
«похоже, запустил поток с именем [MyScheduler_Worker-1], но не смог его остановить».
Но позже я вижу это сообщение:
«[DEBUG] 28 сен, 11:45: 26.671 AM MyScheduler_Worker-1 [org.quartz.simpl.SimpleThreadPool]
WorkerThread отключен».
Итак Можно ли предположить, что из-за этого потока нет утечки памяти?
Вот как выглядит мой журнал:
{SEVERE: The web application [/*************] appears to have started a thread
named [MyScheduler_Worker-1] but has failed to stop it. This is very likely to c
reate a memory leak.
Sep 28, 2011 11:45:26 AM org.apache.catalina.loader.WebappClassLoader clearRefer
encesThreads
SEVERE: The web application [/*************] appears to have started a thread
named [MyScheduler_Worker-2] but has failed to stop it. This is very likely to c
reate a memory leak.
Sep 28, 2011 11:45:26 AM org.apache.catalina.loader.WebappClassLoader clearRefer
encesThreads
SEVERE: The web application [/*************] appears to have started a thread
named [MyScheduler_Worker-3] but has failed to stop it. This is very likely to c
reate a memory leak.
[DEBUG] 28 Sep 11:45:26.671 AM MyScheduler_Worker-2 [org.quartz.simpl.SimpleThre
adPool]
WorkerThread is shut down.
[DEBUG] 28 Sep 11:45:26.671 AM MyScheduler_Worker-1 [org.quartz.simpl.SimpleThre
adPool]
WorkerThread is shut down.
[DEBUG] 28 Sep 11:45:26.671 AM MyScheduler_Worker-3 [org.quartz.simpl.SimpleThre
adPool]
WorkerThread is shut down.