mirror of https://github.com/apache/cassandra
Choose better poolingOptions for protocol v4 in cassandra-stress
Patch by tjake; reviewed by Alan Boudreault for CASSANDRA-10182
This commit is contained in:
parent
f00a3da835
commit
16b9f8bba4
|
|
@ -1,4 +1,5 @@
|
|||
3.0.0-beta2
|
||||
* Choose better poolingOptions for protocol v4 in cassandra-stress (CASSANDRA-10182)
|
||||
* Fix LWW bug affecting Materialized Views (CASSANDRA-10197)
|
||||
* Ensures frozen sets and maps are always sorted (CASSANDRA-10162)
|
||||
* Don't deadlock when flushing CFS backed custom indexes (CASSANDRA-10181)
|
||||
|
|
|
|||
|
|
@ -89,13 +89,17 @@ public class JavaDriverClient
|
|||
|
||||
public void connect(ProtocolOptions.Compression compression) throws Exception
|
||||
{
|
||||
PoolingOptions poolingOpts = new PoolingOptions();
|
||||
poolingOpts.setCoreConnectionsPerHost(HostDistance.LOCAL, 8);
|
||||
|
||||
PoolingOptions poolingOpts = new PoolingOptions()
|
||||
.setConnectionsPerHost(HostDistance.LOCAL, 8, 8)
|
||||
.setMaxRequestsPerConnection(HostDistance.LOCAL, 128)
|
||||
.setNewConnectionThreshold(HostDistance.LOCAL, 100);
|
||||
|
||||
Cluster.Builder clusterBuilder = Cluster.builder()
|
||||
.addContactPoint(host)
|
||||
.withPort(port)
|
||||
.withPoolingOptions(poolingOpts)
|
||||
.withProtocolVersion(ProtocolVersion.V2)
|
||||
.withoutJMXReporting()
|
||||
.withoutMetrics(); // The driver uses metrics 3 with conflict with our version
|
||||
if (whitelist != null)
|
||||
clusterBuilder.withLoadBalancingPolicy(whitelist);
|
||||
|
|
|
|||
Loading…
Reference in New Issue