Well, I've heard of that problem, but I'm not sure it really exists.

1. I've profiled the bisocket code without finding any leak.

2. When java.util.TimerTask.cancel() is called it sets its "state" variable to 
"CANCELLED".  Now, java.util.TimerThread.mainLoop() does this:


  |                     task = queue.getMin();
  |                     synchronized(task.lock) {
  |                         if (task.state == TimerTask.CANCELLED) {
  |                             queue.removeMin();
  |                             continue;  // No action required, poll queue 
again
  |                         }
  | 

so the first time the cancelled TimerTask gets run, it should be removed from 
the java.util.Timer's queue.

3. BisocketSocketInvoker will recreate its Timer if the Timer has shut itself 
down, but the reference to the old Timer would be lost, so the old Timer should 
get garbage collected eventually.

If I'm wrong about anything here, or if I'm missing something, please let me 
know.

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4160712#4160712

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4160712
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to