git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@819493 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Bosanac Dejan 2009-09-28 10:37:57 +00:00
parent 87cdbbe961
commit 74148299dc
1 changed files with 1 additions and 0 deletions

View File

@ -183,6 +183,7 @@ public class AMQ2413Test extends CombinationTestSupport implements MessageListen
try {
while (count.get() < SEND_COUNT) {
if (!receivedMessages.tryAcquire(HANG_THRESHOLD, TimeUnit.SECONDS)) {
if (count.get() == SEND_COUNT) break;
throw new TimeoutException("Message not received for more than " + HANG_THRESHOLD + " seconds");
}
}