changeset 844:421e04bfc24b

minor
author Devel 1
date Tue, 23 Jan 2018 12:12:00 +0100
parents 393e5b6f9f7b
children 80b23882a893
files stress-tester/src/main/java/com/passus/st/client/http/ReporterNodeDefinitionCreator.java
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/stress-tester/src/main/java/com/passus/st/client/http/ReporterNodeDefinitionCreator.java	Tue Jan 23 11:39:31 2018 +0100
+++ b/stress-tester/src/main/java/com/passus/st/client/http/ReporterNodeDefinitionCreator.java	Tue Jan 23 12:12:00 2018 +0100
@@ -6,6 +6,7 @@
 import com.passus.st.validation.PortValidator;
 
 import static com.passus.config.schema.ConfigurationSchemaBuilder.*;
+import com.passus.config.validation.LongValidator;
 
 public class ReporterNodeDefinitionCreator implements NodeDefinitionCreator {
 
@@ -19,7 +20,7 @@
                 tupleDef("active", valueDefBool()).setRequired(false),
                 tupleDef("host", valueDef()).setRequired(false),
                 tupleDef("port", valueDefInteger().addValidator(PortValidator.INSTANCE)).setRequired(false),
-                tupleDef("threads", valueDefInteger()).setRequired(false),
+                tupleDef("threads", valueDefInteger().addValidator(LongValidator.GREATER_ZERO)).setRequired(false),
                 tupleDef("destinations", createDestinationsListDef()).setRequired(false)
         );
     }