Object conn = ds.createPoolOrConnection();
Cluster cluster = (Cluster) conn;
HostDistance distance = HostDistance.LOCAL;
Configuration configuration = cluster.getConfiguration();
Assert.assertEquals(configuration.getSocketOptions().getReadTimeoutMillis(), 110000);
Assert.assertEquals(configuration.getSocketOptions().getKeepAlive().booleanValue(), false);
Assert.assertEquals(configuration.getSocketOptions().getReceiveBufferSize().intValue(), 12);
Assert.assertEquals(configuration.getSocketOptions().getReuseAddress().booleanValue(), true);
Assert.assertEquals(configuration.getSocketOptions().getSendBufferSize().intValue(), 11);
Assert.assertEquals(configuration.getSocketOptions().getSoLinger().intValue(), 10);
Assert.assertEquals(configuration.getSocketOptions().getTcpNoDelay().booleanValue(), true);
Assert.assertEquals(configuration.getPoolingOptions().getCoreConnectionsPerHost(distance), 5);
Assert.assertEquals(configuration.getPoolingOptions().getMaxConnectionsPerHost(distance), 12);
Assert.assertEquals(configuration.getPoolingOptions()
.getMaxSimultaneousRequestsPerConnectionThreshold(distance), 200);
Assert.assertEquals(configuration.getPoolingOptions()
.getMinSimultaneousRequestsPerConnectionThreshold(distance), 65);
Assert.assertEquals(configuration.getPolicies().getLoadBalancingPolicy().getClass().getName(),
LatencyAwarePolicy.class.getName());
Assert.assertEquals(configuration.getPolicies().getReconnectionPolicy().getClass().getName(), CRP);
Assert.assertEquals(configuration.getPolicies().getRetryPolicy().getClass().getName(), LRTP);
Assert.assertEquals(connectionProperties.getProperty("constantDelayMs"), "110000");
Assert.assertEquals(connectionProperties.getProperty("localdc"), "dc1");
Assert.assertEquals(connectionProperties.getProperty("usedHostsPerRemoteDc"), "2");
Assert.assertEquals(connectionProperties.getProperty("isLatencyAware"), "true");