diff --git a/CHANGES.txt b/CHANGES.txt index dfb849d532..c4f4c1f8ef 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -1,4 +1,5 @@ 3.12 + * Add timeUnit Days for cassandra-stress (CASSANDRA-13029) * Add mutation size and batch metrics (CASSANDRA-12649) * Add method to get size of endpoints to TokenMetadata (CASSANDRA-12999) * Fix primary index calculation for SASI (CASSANDRA-12910) diff --git a/tools/stress/src/org/apache/cassandra/stress/settings/SettingsCommand.java b/tools/stress/src/org/apache/cassandra/stress/settings/SettingsCommand.java index c3a171e7a6..1416b8bb18 100644 --- a/tools/stress/src/org/apache/cassandra/stress/settings/SettingsCommand.java +++ b/tools/stress/src/org/apache/cassandra/stress/settings/SettingsCommand.java @@ -96,6 +96,9 @@ public abstract class SettingsCommand implements Serializable case 'h': this.durationUnits = TimeUnit.HOURS; break; + case 'd': + this.durationUnits = TimeUnit.DAYS; + break; default: throw new IllegalStateException(); } @@ -135,7 +138,7 @@ public abstract class SettingsCommand implements Serializable static class Duration extends Options { - final OptionSimple duration = new OptionSimple("duration=", "[0-9]+[smh]", null, "Time to run in (in seconds, minutes or hours)", true); + final OptionSimple duration = new OptionSimple("duration=", "[0-9]+[smhd]", null, "Time to run in (in seconds, minutes, hours or days)", true); @Override public List options() {