User: chirino 
  Date: 01/10/01 16:53:33

  Modified:    src/main/org/jboss/mq Connection.java
  Log:
  Adjusted the ClockDeamon used to monitor thread connections so that it uses a deamon 
thread.  This allows the VM to exit when all connections are closed.
  
  Revision  Changes    Path
  1.8       +12 -1     jbossmq/src/main/org/jboss/mq/Connection.java
  
  Index: Connection.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbossmq/src/main/org/jboss/mq/Connection.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- Connection.java   2001/09/27 03:27:42     1.7
  +++ Connection.java   2001/10/01 23:53:33     1.8
  @@ -7,6 +7,7 @@
   package org.jboss.mq;
   import EDU.oswego.cs.dl.util.concurrent.Semaphore;
   import EDU.oswego.cs.dl.util.concurrent.ClockDaemon;
  +import EDU.oswego.cs.dl.util.concurrent.ThreadFactory;
   
   import java.io.File;
   import java.io.FileInputStream;
  @@ -37,7 +38,7 @@
    *
    * @author    Norbert Lataille ([EMAIL PROTECTED])
    * @author    Hiram Chirino ([EMAIL PROTECTED])
  - * @version   $Revision: 1.7 $
  + * @version   $Revision: 1.8 $
    * @created   August 16, 2001
    */
   public class Connection implements java.io.Serializable, javax.jms.Connection
  @@ -1021,6 +1022,16 @@
            return;
         
         pingTaskId = clockDaemon.executePeriodically(pingPeriod,new PingTask(), true);
  +      clockDaemon.setThreadFactory(
  +         new ThreadFactory () {
  +            public Thread newThread(Runnable r) {
  +               Thread t = new Thread(threadGroup, r, "Connection Monitor Thread");
  +               t.setDaemon(true);
  +               return t;
  +            }
  +         }
  +      
  +      );
      }
      
      private void stopPingThread() {
  
  
  

_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to