[jboss-cvs] JBossAS SVN: r76149 - trunk/tomcat/src/main/org/jboss/web/tomcat/service/modcluster/ha.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Wed Jul 23 17:35:51 EDT 2008
Author: bstansberry at jboss.com
Date: 2008-07-23 17:35:51 -0400 (Wed, 23 Jul 2008)
New Revision: 76149
Modified:
trunk/tomcat/src/main/org/jboss/web/tomcat/service/modcluster/ha/ModClusterServiceHASingletonElectionPolicy.java
Log:
[JBAS-5659] Handle null candidates (happens during shutdown)
Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/service/modcluster/ha/ModClusterServiceHASingletonElectionPolicy.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/service/modcluster/ha/ModClusterServiceHASingletonElectionPolicy.java 2008-07-23 21:35:12 UTC (rev 76148)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/service/modcluster/ha/ModClusterServiceHASingletonElectionPolicy.java 2008-07-23 21:35:51 UTC (rev 76149)
@@ -47,8 +47,12 @@
@Override
protected ClusterNode elect(List<ClusterNode> candidates)
{
+ if (candidates == null)
+ return null;
+
if (candidates.size() == 1)
return candidates.get(0);
+
return delegate.elect(candidates);
}
@@ -62,6 +66,9 @@
public List<ClusterNode> narrowCandidateList(Collection<ModClusterServiceDRMEntry> candidates)
{
+ if (candidates == null)
+ return null;
+
List<ClusterNode> narrowed = new ArrayList<ClusterNode>();
ModClusterServiceDRMEntry champion = null;
More information about the jboss-cvs-commits
mailing list