changeset 496:edc36abb1445

minor
author Devel 1
date Wed, 16 Aug 2017 09:13:27 +0200
parents a9ad9e016d6c
children 874079c35460
files stress-tester/src/main/java/com/passus/st/client/http/HttpScopes.java stress-tester/src/main/java/com/passus/st/client/http/filter/HttpMessageModificationFilterTransformer.java stress-tester/src/main/java/com/passus/st/client/http/filter/HttpResponseContentExtractorFilter.java
diffstat 3 files changed, 7 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/stress-tester/src/main/java/com/passus/st/client/http/HttpScopes.java	Sat Aug 12 18:12:11 2017 +0200
+++ b/stress-tester/src/main/java/com/passus/st/client/http/HttpScopes.java	Wed Aug 16 09:13:27 2017 +0200
@@ -93,15 +93,15 @@
     }
 
     public ParametersBag getSession(String sessionId) {
-        return HttpScopes.this.getSession(sessionId, ZONE_DEFAULT);
+        return getSession(sessionId, ZONE_DEFAULT);
     }
 
     public ParametersBag getSession(String sessionId, String zone) {
-        return HttpScopes.this.getSession(sessionId, zone, true);
+        return getSession(sessionId, zone, true);
     }
 
     public ParametersBag getSession(String sessionId, boolean autocreate) {
-        return HttpScopes.this.getSession(sessionId, ZONE_DEFAULT, autocreate);
+        return getSession(sessionId, ZONE_DEFAULT, autocreate);
     }
 
     public ParametersBag getSession(String sessionId, String zone, boolean autocreate) {
--- a/stress-tester/src/main/java/com/passus/st/client/http/filter/HttpMessageModificationFilterTransformer.java	Sat Aug 12 18:12:11 2017 +0200
+++ b/stress-tester/src/main/java/com/passus/st/client/http/filter/HttpMessageModificationFilterTransformer.java	Wed Aug 16 09:13:27 2017 +0200
@@ -109,7 +109,7 @@
     }
 
     @Override
-    public CNode transform(CNode node, Errors errors) {
+    public CValueNode transform(CNode node, Errors errors) {
         CMapNode mapNode = (CMapNode) node;
 
         List<CTupleNode> tuples = mapNode.getChildren();
@@ -117,7 +117,7 @@
         if (tuples.isEmpty()) {
             operations = Collections.EMPTY_LIST;
         } else {
-            operations = new ArrayList<>();
+            operations = new ArrayList<>(tuples.size());
         }
 
         for (CTupleNode tuple : tuples) {
--- a/stress-tester/src/main/java/com/passus/st/client/http/filter/HttpResponseContentExtractorFilter.java	Sat Aug 12 18:12:11 2017 +0200
+++ b/stress-tester/src/main/java/com/passus/st/client/http/filter/HttpResponseContentExtractorFilter.java	Wed Aug 16 09:13:27 2017 +0200
@@ -5,13 +5,11 @@
 import com.passus.config.Configuration;
 import com.passus.config.annotations.NodeDefinitionCreate;
 import static com.passus.config.schema.ConfigurationSchemaBuilder.mapDef;
-import static com.passus.config.schema.ConfigurationSchemaBuilder.mixedDef;
 import static com.passus.config.schema.ConfigurationSchemaBuilder.tupleDef;
 import static com.passus.config.schema.ConfigurationSchemaBuilder.valueDef;
 import static com.passus.config.schema.ConfigurationSchemaBuilder.valueDefBool;
 import com.passus.config.schema.KeyNameVaryListNodeDefinition;
 import com.passus.config.schema.MapNodeDefinition;
-import com.passus.config.schema.MixedNodeDefinition;
 import com.passus.config.schema.NodeDefinition;
 import com.passus.config.schema.NodeDefinitionCreator;
 import com.passus.net.http.HttpRequest;
@@ -79,6 +77,7 @@
                 try {
                     String value = contentExtractor.extract(response);
                     params.set(paramName, value);
+                    LOGGER.debug("Session variable created {}={}", paramName, value);
                 } catch (IOException ex) {
                     LOGGER.info("Could not read message body", ex);
                 }
@@ -102,6 +101,7 @@
             try {
                 String value = contentExtractor.extract(response);
                 params.set(paramName, value);
+                LOGGER.debug("Global variable created {}={}", paramName, value);
             } catch (IOException ex) {
                 LOGGER.info("Could not read message body", ex);
             }