This closes #359

This commit is contained in:
Clebert Suconic 2016-01-29 09:30:11 -05:00
commit 0d6e6a35f5
1 changed files with 10 additions and 1 deletions

View File

@ -570,7 +570,16 @@ public class TemporaryQueueTest extends SingleServerTestBase {
Thread.sleep(100);
}
while (t.isAlive() && errors.get() == 0 && !prod.getProducerCredits().isBlocked()) {
int blockedTime = 0;
// https://issues.apache.org/jira/browse/ARTEMIS-368
while (t.isAlive() && errors.get() == 0 && (!prod.getProducerCredits().isBlocked() || blockedTime < 60)) {
if (prod.getProducerCredits().isBlocked()) {
blockedTime++;
}
else {
blockedTime = 0;
}
Thread.sleep(100);
}