YARN-1537. Fix race condition in TestLocalResourcesTrackerImpl.testLocalResourceCache. Contributed by Xuan Gong.
This commit is contained in:
parent
18b2507eda
commit
02f154a001
@ -498,6 +498,9 @@ Release 2.7.0 - UNRELEASED
|
||||
YARN-3145. Fixed ConcurrentModificationException on CapacityScheduler
|
||||
ParentQueue#getQueueUserAclInfo. (Tsuyoshi OZAWA via jianhe)
|
||||
|
||||
YARN-1537. Fix race condition in
|
||||
TestLocalResourcesTrackerImpl.testLocalResourceCache. (xgong via acmurthy)
|
||||
|
||||
Release 2.6.0 - 2014-11-18
|
||||
|
||||
INCOMPATIBLE CHANGES
|
||||
|
@ -24,6 +24,7 @@
|
||||
import static org.mockito.Mockito.mock;
|
||||
import static org.mockito.Mockito.times;
|
||||
import static org.mockito.Mockito.verify;
|
||||
import static org.mockito.Mockito.timeout;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@ -313,7 +314,7 @@ public void testLocalResourceCache() {
|
||||
// After receiving failed resource event; all waiting containers will be
|
||||
// notified with Container Resource Failed Event.
|
||||
Assert.assertEquals(0, localrsrc.size());
|
||||
verify(containerEventHandler, times(2)).handle(
|
||||
verify(containerEventHandler, timeout(1000).times(2)).handle(
|
||||
isA(ContainerResourceFailedEvent.class));
|
||||
Assert.assertEquals(ResourceState.FAILED, localizedResource.getState());
|
||||
|
||||
@ -360,7 +361,7 @@ public void testLocalResourceCache() {
|
||||
dispatcher.await();
|
||||
|
||||
// Verifying ContainerResourceLocalizedEvent .
|
||||
verify(containerEventHandler, times(1)).handle(
|
||||
verify(containerEventHandler, timeout(1000).times(1)).handle(
|
||||
isA(ContainerResourceLocalizedEvent.class));
|
||||
Assert.assertEquals(ResourceState.LOCALIZED, localrsrc.get(lr)
|
||||
.getState());
|
||||
|
Loading…
Reference in New Issue
Block a user