Search in sources :

Example 1 with Blacklist

use of com.palantir.atlasdb.keyvalue.cassandra.Blacklist in project atlasdb by palantir.

the class CassandraServiceTest method clientPoolWith.

private CassandraService clientPoolWith(ImmutableSet<InetSocketAddress> servers, ImmutableSet<InetSocketAddress> serversInPool) {
    config = ImmutableCassandraKeyValueServiceConfig.builder().replicationFactor(3).addServers(servers.toArray(new InetSocketAddress[0])).build();
    blacklist = new Blacklist(config);
    CassandraService service = new CassandraService(config, blacklist, new FakeQosClient());
    service.cacheInitialCassandraHosts();
    serversInPool.forEach(service::addPool);
    return service;
}
Also used : InetSocketAddress(java.net.InetSocketAddress) FakeQosClient(com.palantir.atlasdb.qos.FakeQosClient) Blacklist(com.palantir.atlasdb.keyvalue.cassandra.Blacklist)

Aggregations

Blacklist (com.palantir.atlasdb.keyvalue.cassandra.Blacklist)1 FakeQosClient (com.palantir.atlasdb.qos.FakeQosClient)1 InetSocketAddress (java.net.InetSocketAddress)1