[jboss-cvs] JBossAS SVN: r109708 - in branches/JBoss-AS-6.0.x-ipv6/testsuite/src: resources/cluster/hasingleton/electionpolicy and 1 other directory.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Fri Dec 3 13:40:03 EST 2010
Author: rachmatowicz at jboss.com
Date: 2010-12-03 13:40:02 -0500 (Fri, 03 Dec 2010)
New Revision: 109708
Modified:
branches/JBoss-AS-6.0.x-ipv6/testsuite/src/main/org/jboss/test/cluster/defaultcfg/test/PreferredMasterElectionPolicyUnitTestCase.java
branches/JBoss-AS-6.0.x-ipv6/testsuite/src/resources/cluster/hasingleton/electionpolicy/ha-electionpolicy-jboss-beans.xml
Log:
Fix up URLs in PreferredMasterElectionPolicyUnitTestCase and HASingletonElectionPolicyTestCase (JBAS-8540)
Modified: branches/JBoss-AS-6.0.x-ipv6/testsuite/src/main/org/jboss/test/cluster/defaultcfg/test/PreferredMasterElectionPolicyUnitTestCase.java
===================================================================
--- branches/JBoss-AS-6.0.x-ipv6/testsuite/src/main/org/jboss/test/cluster/defaultcfg/test/PreferredMasterElectionPolicyUnitTestCase.java 2010-12-03 16:02:02 UTC (rev 109707)
+++ branches/JBoss-AS-6.0.x-ipv6/testsuite/src/main/org/jboss/test/cluster/defaultcfg/test/PreferredMasterElectionPolicyUnitTestCase.java 2010-12-03 18:40:02 UTC (rev 109708)
@@ -85,7 +85,13 @@
public void testUsePreferredMasterViaAddress()
{
- this.policy.setPreferredMaster("127.0.0.1:10002");
+ // JBAS-8540
+ String hostport = "[::1]:10002" ;
+ // check for IPv4 stack and use correct address literal
+ if (System.getProperty("java.net.preferIPv4Stack").equals("true"))
+ hostport = "127.0.0.1:10002" ;
+
+ this.policy.setPreferredMaster(hostport);
ClusterNode master = this.policy.elect(this.candidates);
Modified: branches/JBoss-AS-6.0.x-ipv6/testsuite/src/resources/cluster/hasingleton/electionpolicy/ha-electionpolicy-jboss-beans.xml
===================================================================
--- branches/JBoss-AS-6.0.x-ipv6/testsuite/src/resources/cluster/hasingleton/electionpolicy/ha-electionpolicy-jboss-beans.xml 2010-12-03 16:02:02 UTC (rev 109707)
+++ branches/JBoss-AS-6.0.x-ipv6/testsuite/src/resources/cluster/hasingleton/electionpolicy/ha-electionpolicy-jboss-beans.xml 2010-12-03 18:40:02 UTC (rev 109708)
@@ -105,7 +105,8 @@
<bean class="org.jboss.ha.singleton.PreferredMasterElectionPolicy"
name="PreferredMasterElectionPolicy_1">
<property name="position">0</property>
- <property name="preferredMaster">${node0.bind.address:127.0.0.1}:1099</property>
+ <!-- JBAS-8540 -->
+ <property name="preferredMaster">${node0.bind.address.url:localhost}:1099</property>
</bean>
<bean class="org.jboss.ha.singleton.HASingletonController"
@@ -130,7 +131,8 @@
<bean class="org.jboss.ha.singleton.PreferredMasterElectionPolicy"
name="PreferredMasterElectionPolicy_2">
<property name="position">-1</property>
- <property name="preferredMaster">${node0.bind.address:127.0.0.1}:1099</property>
+ <!-- JBAS-8540 -->
+ <property name="preferredMaster">${node0.bind.address.url:localhost}:1099</property>
</bean>
<bean class="org.jboss.ha.singleton.HASingletonController"
More information about the jboss-cvs-commits
mailing list