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 | 6d24037cda88c21c8e68cf9ca57f61365e957b98 (patch) | |
| tree | 6282fba7b5a180894e5272d4afc2d7de27b7abfa /java/systests | |
| parent | 9b3dc6ee58732c7a380de8224fc23065afbcfe1d (diff) | |
| download | qpid-python-6d24037cda88c21c8e68cf9ca57f61365e957b98.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/qpid@1546331 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/systests')
| -rw-r--r-- | java/systests/junitvmwatcher3451231054183359611.properties | 1 | ||||
| -rw-r--r-- | java/systests/src/main/java/org/apache/qpid/client/failover/MultipleBrokersFailoverTest.java | 9 |
2 files changed, 7 insertions, 3 deletions
diff --git a/java/systests/junitvmwatcher3451231054183359611.properties b/java/systests/junitvmwatcher3451231054183359611.properties new file mode 100644 index 0000000000..da309e1083 --- /dev/null +++ b/java/systests/junitvmwatcher3451231054183359611.properties @@ -0,0 +1 @@ +testHeartbeatsEnabledUsingOlderLegacySystemProperty diff --git a/java/systests/src/main/java/org/apache/qpid/client/failover/MultipleBrokersFailoverTest.java b/java/systests/src/main/java/org/apache/qpid/client/failover/MultipleBrokersFailoverTest.java index a0fd093bfe..afc630296d 100644 --- a/java/systests/src/main/java/org/apache/qpid/client/failover/MultipleBrokersFailoverTest.java +++ b/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); |
