[jboss-dev-forums] [Design of Messaging on JBoss (Messaging/JBoss)] - Re: Another DeadLock, something around InVM

clebert.suconic@jboss.com do-not-reply at jboss.com
Thu Mar 5 09:25:59 EST 2009


I could fix PingStressTest by adding this fix:


  | Index: src/main/org/jboss/messaging/core/remoting/impl/RemotingConnectionImpl.java
  | ===================================================================
  | --- src/main/org/jboss/messaging/core/remoting/impl/RemotingConnectionImpl.java	(revision 6007)
  | +++ src/main/org/jboss/messaging/core/remoting/impl/RemotingConnectionImpl.java	(working copy)
  | @@ -417,10 +417,17 @@
  |  
  |        log.warn("Connection failed, client " + client + " " + System.identityHashCode(this) + " " + me.getMessage(), me);
  |  
  | -      // Then call the listeners
  | -      callListeners(me);
  | +      // Using another thread to avoid a hang or dead lock (another thread waiting an executor to finish, while it holds the lock)
  | +      new Thread()
  | +      {
  | +         public void run()
  | +         {
  | +            // Then call the listeners
  | +            callListeners(me);
  |  
  | -      internalClose();
  | +            internalClose();
  | +         }
  | +      }.start();
  |     }
  |  
  |     public void destroy()
  | 
  | 


Unless you guys find something wrong with it, I will commit it and enable PingStressTest with 20 iterations. (I have also changed the calling timeout on the test, what would make the stress-test to run faster)

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

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4215320



More information about the jboss-dev-forums mailing list