connector1.connect(20);
connector2.connect(20);
assertTrue("Failed to connect", connector1.awaitJoined(5, TimeUnit.SECONDS));
assertTrue("Failed to connect", connector2.awaitJoined(5, TimeUnit.SECONDS));
DistributedCommandBus bus1 = new DistributedCommandBus(connector1, new AnnotationRoutingStrategy(
UnresolvedRoutingKeyPolicy.RANDOM_KEY));
CommandGateway gateway1 = new DefaultCommandGateway(bus1);
doThrow(new RuntimeException("Mock")).when(serializer).deserialize(argThat(new TypeSafeMatcher<SerializedObject<byte[]>>() {
@Override