[Jboss-cvs] JBossAS SVN: r56862 - branches/Branch_4_0/cluster/src/main/org/jboss/ha/framework/server

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Thu Sep 14 15:25:31 EDT 2006


Author: bstansberry at jboss.com
Date: 2006-09-14 15:25:31 -0400 (Thu, 14 Sep 2006)
New Revision: 56862

Modified:
   branches/Branch_4_0/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java
Log:
[JBAS-3656] Disconnect HAPartition channel upon failure in startService()

Modified: branches/Branch_4_0/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java
===================================================================
--- branches/Branch_4_0/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java	2006-09-14 19:23:07 UTC (rev 56861)
+++ branches/Branch_4_0/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java	2006-09-14 19:25:31 UTC (rev 56862)
@@ -335,10 +335,19 @@
       log.debug("Starting ClusterPartition: " + partitionName);
       channel.connect(partitionName);
       
-      log.debug("Starting channel");
-      partition.startPartition();
+      try
+      {
+         log.debug("Starting channel");
+         partition.startPartition();
 
-      log.debug("Started ClusterPartition: " + partitionName);
+         log.debug("Started ClusterPartition: " + partitionName);         
+      }
+      catch (Exception e)
+      {
+         log.debug("Caught exception after channel connected; closing channel -- " + e.getLocalizedMessage());
+         channel.disconnect();
+         throw e;
+      }
    }
    
    protected void stopService() throws Exception




More information about the jboss-cvs-commits mailing list