jmeter-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [jmeter] ham1 commented on a change in pull request #638: Bolt Sampler - Neo4j 4.x and cluster features
Date Sun, 10 Jan 2021 04:24:08 GMT

ham1 commented on a change in pull request #638:
URL: https://github.com/apache/jmeter/pull/638#discussion_r554373945



##########
File path: src/protocol/bolt/src/main/java/org/apache/jmeter/protocol/bolt/sampler/AbstractBoltTestElement.java
##########
@@ -17,13 +17,53 @@
 
 package org.apache.jmeter.protocol.bolt.sampler;
 
+import java.time.Duration;
+
+import org.apache.commons.lang3.EnumUtils;
+import org.apache.commons.lang3.StringUtils;
 import org.apache.jmeter.testelement.AbstractTestElement;
+import org.neo4j.driver.AccessMode;
+import org.neo4j.driver.SessionConfig;
+import org.neo4j.driver.TransactionConfig;
 
 public abstract class AbstractBoltTestElement extends AbstractTestElement {
 
     private String cypher;
     private String params;
+    private String database;
+    private String accessMode;
     private boolean recordQueryResults;
+    private int txTimeout;
+
+    public int getTxTimeout() {
+        return txTimeout;
+    }
+
+    public void setTxTimeout(int txTimeout) {
+        this.txTimeout = txTimeout;
+    }
+
+    public String getAccessMode() {
+        if (accessMode != null) {

Review comment:
       Consider writing this using a guard clause? i.e.
   ```
   if (accessMode == null) {
       return AccessMode.WRITE.toString();
   }
   return accessMode;
   ```




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



Mime
View raw message