This commit is contained in:
Rob Austin
2014-11-04 14:44:59 +00:00
parent a0c89935f5
commit 9dec1ed4db
64 changed files with 700 additions and 865 deletions
@@ -18,7 +18,6 @@
package net.openhft.chronicle.set;
import net.openhft.chronicle.hash.replication.TcpConfig;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
@@ -26,11 +25,10 @@ import org.junit.Test;
import java.io.Closeable;
import java.io.IOException;
import java.net.InetSocketAddress;
import java.util.Arrays;
import static java.util.Arrays.asList;
import static java.util.concurrent.TimeUnit.SECONDS;
import static net.openhft.chronicle.map.Builder.getPersistenceFile;
import static net.openhft.chronicle.hash.TcpReplicationConfig.of;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
@@ -53,9 +51,10 @@ public class SetForTCPSocketReplicationTest3way {
final int serverPort,
final InetSocketAddress... endpoints) throws IOException {
return (T) ChronicleSetBuilder.of(Integer.class)
.replication(identifier, TcpConfig.unknownTopology(serverPort, asList(endpoints))
.file(getPersistenceFile())
.replicators(identifier, of(serverPort, endpoints)
.heartBeatInterval(1L, SECONDS))
.createPersistedTo(getPersistenceFile());
.create();
}