Author: clebert.suconic(a)jboss.com
Date: 2011-10-31 18:27:51 -0400 (Mon, 31 Oct 2011)
New Revision: 11622
Modified:
branches/Branch_2_2_EAP/src/main/org/hornetq/core/client/impl/ServerLocatorImpl.java
Log:
fixing a deadlock on discoveryGroup.stop()
Modified:
branches/Branch_2_2_EAP/src/main/org/hornetq/core/client/impl/ServerLocatorImpl.java
===================================================================
---
branches/Branch_2_2_EAP/src/main/org/hornetq/core/client/impl/ServerLocatorImpl.java 2011-10-31
19:20:04 UTC (rev 11621)
+++
branches/Branch_2_2_EAP/src/main/org/hornetq/core/client/impl/ServerLocatorImpl.java 2011-10-31
22:27:51 UTC (rev 11622)
@@ -1243,9 +1243,9 @@
state = STATE.CLOSING;
- synchronized (this)
+ if (discoveryGroup != null)
{
- if (discoveryGroup != null)
+ synchronized (this)
{
try
{
@@ -1256,11 +1256,11 @@
log.error("Failed to stop discovery group", e);
}
}
- else
- {
- staticConnector.disconnect();
- }
}
+ else
+ {
+ staticConnector.disconnect();
+ }
synchronized (connectingFactories)
{
Show replies by date