added in a fix for net.openhft.chronicle.map.ReplicateProxyMapUpdatedViaSharedMemoryTest.testReplicateProxyMapUpdatedViaSharedMemory

This commit is contained in:
Rob Austin
2015-05-28 15:34:27 +01:00
parent 163e8bbbe1
commit 2943d2ec6a
7 changed files with 139 additions and 81 deletions
@@ -67,50 +67,6 @@ public class TestReplication {
private ReplicationHub hubOnServer1;
@Test
public void testAllDataGetsReplicated2() throws InterruptedException, IOException, ExecutionException {
try
// server 1 with identifier = 1
{
ChronicleMapBuilder<Short, Short> builder =
ChronicleMapBuilder.of(Short.class, Short.class)
.entries(1000);
byte identifier = (byte) 1;
TcpTransportAndNetworkConfig tcpConfig = TcpTransportAndNetworkConfig
.of(8086);
hubOnServer1 = ReplicationHub.builder()
.tcpTransportAndNetwork(tcpConfig)
.maxNumberOfChannels(SIZE)
.createWithId(identifier);
for (short channel1 = 3; channel1 < SIZE; channel1++) {
ChronicleMap<Short, Short> map = builder.instance()
.replicatedViaChannel(hubOnServer1.createChannel(channel1)).create();
for (int i = 0; i < 10; i++) {
map.put((short) i, (short) i);
}
maps.put(channel1, map);
System.out.println("" + channel1);
}
} catch (Exception e) {
e.printStackTrace();
}
for (; ; ) {
Thread.sleep(1000);
}
}
}