diff options
| author | Keith Wall <kwall@apache.org> | 2013-11-28 10:12:59 +0000 |
|---|---|---|
| committer | Keith Wall <kwall@apache.org> | 2013-11-28 10:12:59 +0000 |
| commit | 4b3a680d3e95943dc6ab6e464cc59768a1224b18 (patch) | |
| tree | 79043756cdacbc671d12b347d1d9f3dd92a8e9db /qpid/java | |
| parent | 26d4b6ad2c1f84c3eba3b4239a3ef8b6ec0b9f44 (diff) | |
| download | qpid-python-4b3a680d3e95943dc6ab6e464cc59768a1224b18.tar.gz | |
NO-JIRA: [Java System Tests] Increase timeout factor used for failover timeout. Test was failing on a slow (virtualised) Jenkins environment.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1546331 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/java')
| -rw-r--r-- | qpid/java/systests/junitvmwatcher3451231054183359611.properties | 1 | ||||
| -rw-r--r-- | qpid/java/systests/src/main/java/org/apache/qpid/client/failover/MultipleBrokersFailoverTest.java | 9 |
2 files changed, 7 insertions, 3 deletions
diff --git a/qpid/java/systests/junitvmwatcher3451231054183359611.properties b/qpid/java/systests/junitvmwatcher3451231054183359611.properties new file mode 100644 index 0000000000..da309e1083 --- /dev/null +++ b/qpid/java/systests/junitvmwatcher3451231054183359611.properties @@ -0,0 +1 @@ +testHeartbeatsEnabledUsingOlderLegacySystemProperty diff --git a/qpid/java/systests/src/main/java/org/apache/qpid/client/failover/MultipleBrokersFailoverTest.java b/qpid/java/systests/src/main/java/org/apache/qpid/client/failover/MultipleBrokersFailoverTest.java index a0fd093bfe..afc630296d 100644 --- a/qpid/java/systests/src/main/java/org/apache/qpid/client/failover/MultipleBrokersFailoverTest.java +++ b/qpid/java/systests/src/main/java/org/apache/qpid/client/failover/MultipleBrokersFailoverTest.java @@ -20,6 +20,7 @@ */ package org.apache.qpid.client.failover; +import java.io.File; import java.util.concurrent.CountDownLatch; import java.util.concurrent.TimeUnit; @@ -49,6 +50,8 @@ public class MultipleBrokersFailoverTest extends QpidBrokerTestCase implements C private static final String BROKER_PORTION_FORMAT = "tcp://localhost:%d?connectdelay='%d',retries='%d'"; private static final int FAILOVER_RETRIES = 1; private static final int FAILOVER_CONNECTDELAY = 1000; + private static final int FAILOVER_FACTOR = 4; + private int[] _brokerPorts; private AMQConnectionURL _connectionURL; private Connection _connection; @@ -149,7 +152,7 @@ public class MultipleBrokersFailoverTest extends QpidBrokerTestCase implements C if (_brokerPorts[i] > 0) { stopBrokerSafely(_brokerPorts[i]); - FileUtils.deleteDirectory(System.getProperty("QPID_WORK") + "/" + getFailingPort()); + FileUtils.deleteDirectory(System.getProperty("QPID_WORK") + File.separator + getFailingPort()); } } @@ -166,7 +169,7 @@ public class MultipleBrokersFailoverTest extends QpidBrokerTestCase implements C killBroker(_brokerPorts[1]); - awaitForFailoverCompletion(FAILOVER_CONNECTDELAY * _brokerPorts.length * 2); + awaitForFailoverCompletion(FAILOVER_CONNECTDELAY * _brokerPorts.length * FAILOVER_FACTOR); assertEquals("Failover is not started as expected", 0, _failoverStarted.getCount()); assertSendReceive(2); @@ -182,7 +185,7 @@ public class MultipleBrokersFailoverTest extends QpidBrokerTestCase implements C stopBroker(_brokerPorts[1]); - awaitForFailoverCompletion(FAILOVER_CONNECTDELAY * _brokerPorts.length * 2); + awaitForFailoverCompletion(FAILOVER_CONNECTDELAY * _brokerPorts.length * FAILOVER_FACTOR); assertEquals("Failover is not started as expected", 0, _failoverStarted.getCount()); assertSendReceive(1); |
