NO-JIRA fix on JMSBridgeTestBase

This commit is contained in:
Clebert Suconic 2018-11-14 10:31:33 -05:00
parent ff5f1213bb
commit d6ffa8b426
2 changed files with 6 additions and 4 deletions

View File

@ -423,7 +423,7 @@ public abstract class BridgeTestBase extends ActiveMQTestBase {
// Consume the messages
for (int i = 0; i < numMessages; i++) {
Message tm = cons.receive(30000);
Message tm = cons.receive(3000);
Assert.assertNotNull(tm);
@ -481,8 +481,10 @@ public abstract class BridgeTestBase extends ActiveMQTestBase {
managementService = server1.getManagementService();
}
QueueControl queueControl = (QueueControl) managementService.getResource("queue." + queueName);
if (queueControl != null) {
queueControl.removeMessages(null);
}
}
protected TransactionManager newTransactionManager() {
return new TransactionManagerImple();

View File

@ -1164,7 +1164,7 @@ public class JMSBridgeTest extends BridgeTestBase {
Assert.assertEquals(0, tm.getJMSExpiration());
m = cons.receive(5000);
m = cons.receive(500);
Assert.assertNull(m);
@ -1615,7 +1615,7 @@ public class JMSBridgeTest extends BridgeTestBase {
try {
final int NUM_MESSAGES = 10;
bridge = new JMSBridgeImpl(factInUse0, factInUse0, sourceQueueFactory, localTargetQueueFactory, null, null, null, null, null, 5000, 10, qosMode, NUM_MESSAGES, -1, null, null, false).setBridgeName("test-bridge");
bridge = new JMSBridgeImpl(factInUse0, factInUse0, sourceQueueFactory, localTargetQueueFactory, null, null, null, null, null, 500, 10, qosMode, NUM_MESSAGES, -1, null, null, false).setBridgeName("test-bridge");
bridge.start();