changeset 1080:f93f0bfb7338

UnidirectionalRawPacketEmitter - only one worker
author Devel 2
date Wed, 29 Apr 2020 14:46:07 +0200
parents b6397f2033d9
children dd0dad00725c
files stress-tester/src/main/java/com/passus/st/emitter/raw/UnidirectionalRawPacketEmitter.java
diffstat 1 files changed, 5 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/stress-tester/src/main/java/com/passus/st/emitter/raw/UnidirectionalRawPacketEmitter.java	Wed Apr 29 14:45:25 2020 +0200
+++ b/stress-tester/src/main/java/com/passus/st/emitter/raw/UnidirectionalRawPacketEmitter.java	Wed Apr 29 14:46:07 2020 +0200
@@ -13,7 +13,8 @@
 
 import java.io.IOException;
 
-import static com.passus.config.schema.ConfigurationSchemaBuilder.*;
+import static com.passus.config.schema.ConfigurationSchemaBuilder.tupleDef;
+import static com.passus.config.schema.ConfigurationSchemaBuilder.valueDefInteger;
 import static com.passus.config.validation.ValidatonUtils.OP_GREATER;
 import static com.passus.net.FrameUtils.*;
 
@@ -21,7 +22,7 @@
 
     protected final Logger logger = LogManager.getLogger(getClass());
 
-    private static final int DEFAULT_THREADS = 4;
+    private static final int DEFAULT_THREADS = 1;
     private static final int DEFAULT_MTU = 1500;
     private static final boolean DEFAULT_COLLECT_METRICS = true;
     private static final int MIN_MTU = ETH_HEADER_LENGTH + IPV4_HEADER_LENGTH + UDP_HEADER_LENGTH;
@@ -206,12 +207,11 @@
         public MapNodeDefinition create() {
             MapNodeDefinition def = super.create();
             def.add(
-                    tupleDef("threads", valueDefInteger().addValidator(LongValidator.GREATER_ZERO)).setRequired(false),
+                    //tupleDef("threads", valueDefInteger().addValidator(LongValidator.GREATER_ZERO)).setRequired(false),
                     tupleDef("mtu", valueDefInteger()
                             .addValidator(new LongValidator((long) MIN_MTU, OP_GREATER))
                     ).setRequired(false),
-                    tupleDef("macResolver", MACAddressResolverNodeDefinitionCreator.createDef()),
-                    tupleDef("collectMetrics", valueDefBool()).setRequired(false)
+                    tupleDef("macResolver", MACAddressResolverNodeDefinitionCreator.createDef())
             );
             return def;
         }