@Test public void testReplicaInfoEvent() throws InterruptedException { final CountDownLatch latch = new CountDownLatch(1); service.addListener(new MasterNodeCheck(latch, DID1, NID1)); eventDispatcher.post(new MastershipEvent(Type.MASTER_CHANGED, DID1, new RoleInfo(NID1, new LinkedList<>()))); assertTrue(latch.await(1, TimeUnit.SECONDS)); }
@Override public void addListener(ReplicaInfoEventListener listener) { listenerRegistry.addListener(checkNotNull(listener)); }
ReplicaInfoManager implements ReplicaInfoService { @Override public void addListener(ReplicaInfoEventListener listener) { listenerRegistry.addListener(checkNotNull(listener)); } }
ReplicaInfoManager implements ReplicaInfoService { @Override public void addListener(ReplicaInfoEventListener listener) { listenerRegistry.addListener(checkNotNull(listener)); }  }
ReplicaInfoManager implements ReplicaInfoService { @Override public void addListener(ReplicaInfoEventListener listener) { listenerRegistry.addListener(checkNotNull(listener)); }  @Activate void activate(); @Deactivate void deactivate(); @Override ReplicaInfo getReplicaInfoFor(DeviceId deviceId); @Override void addListener(ReplicaInfoEventListener listener); @Override void removeListener(ReplicaInfoEventListener listener); }
ReplicaInfoManager implements ReplicaInfoService { @Override public void addListener(ReplicaInfoEventListener listener) { listenerRegistry.addListener(checkNotNull(listener)); }  @Activate void activate(); @Deactivate void deactivate(); @Override ReplicaInfo getReplicaInfoFor(DeviceId deviceId); @Override void addListener(ReplicaInfoEventListener listener); @Override void removeListener(ReplicaInfoEventListener listener);  }