Merge branch 'cassandra-3.0' into cassandra-3.11

This commit is contained in:
Stefania Alborghetti 2017-08-22 09:33:07 +08:00
commit 59d4c27194
2 changed files with 9 additions and 3 deletions

View File

@ -6,6 +6,7 @@
* Duplicate the buffer before passing it to analyser in SASI operation (CASSANDRA-13512)
* Properly evict pstmts from prepared statements cache (CASSANDRA-13641)
Merged from 3.0:
* Don't let stress write warmup data if n=0 (CASSANDRA-13773)
* Gossip thread slows down when using batch commit log (CASSANDRA-12966)
* Randomize batchlog endpoint selection with only 1 or 2 racks (CASSANDRA-12884)
* Fix digest calculation for counter cells (CASSANDRA-13750)

View File

@ -56,6 +56,13 @@ public class StressAction implements Runnable
// creating keyspace and column families
settings.maybeCreateKeyspaces();
if (settings.command.count == 0)
{
output.println("N=0: SCHEMA CREATED, NOTHING ELSE DONE.");
settings.disconnect();
return;
}
output.println("Sleeping 2s...");
Uninterruptibles.sleepUninterruptibly(2, TimeUnit.SECONDS);
@ -98,9 +105,7 @@ public class StressAction implements Runnable
private void warmup(OpDistributionFactory operations)
{
// do 25% of iterations as warmup but no more than 50k (by default hotspot compiles methods after 10k invocations)
int iterations = (settings.command.count > 0
? Math.min(50000, (int)(settings.command.count * 0.25))
: 50000) * settings.node.nodes.size();
int iterations = Math.min(50000, (int) (settings.command.count * 0.25)) * settings.node.nodes.size();
int threads = 100;
if (settings.rate.maxThreads > 0)