Fix: Use new config getters correctly in CqlActivity

This commit is contained in:
Jonathan Shook
2020-06-18 11:04:03 -05:00
parent efd7e77e8a
commit 7a21ef3dbb

View File

@@ -166,12 +166,13 @@ public class CqlActivity extends SimpleActivity implements Activity, ActivityDef
Optional<ConsistencyLevel> cl = stmtDef.getOptionalParam("cl", String.class).map(ConsistencyLevel::valueOf);
Optional<ConsistencyLevel> serial_cl = stmtDef.getOptionalParam("serial_cl").map(ConsistencyLevel::valueOf);
Optional<Boolean> idempotent = stmtDef.getOptionalParam("idempotent", boolean.class);
Optional<Boolean> idempotent = stmtDef.getOptionalParam("idempotent").map(Boolean::parseBoolean);
StringBuilder psummary = new StringBuilder();
boolean instrument = stmtDef.getOptionalParam("instrument", boolean.class)
.orElse(getParams().getOptionalBoolean("instrument").orElse(false));
boolean instrument = stmtDef.getOptionalParam("instrument",Boolean.class)
.or(() -> getParams().getOptionalBoolean("instrument"))
.orElse(false);
String logresultcsv = stmtDef.getParamOrDefault("logresultcsv", "");