KeeProMise commented on code in PR #6380:
URL: https://github.com/apache/hadoop/pull/6380#discussion_r1443614558


##########
hadoop-hdfs-project/hadoop-hdfs-rbf/src/test/java/org/apache/hadoop/hdfs/server/federation/fairness/TestRouterHandlersFairness.java:
##########
@@ -308,4 +375,28 @@ private void innerCalls(URI address, int numOps, boolean 
isConcurrent,
       overloadException.get();
     }
   }
+
+  private static Map<String, Integer> expectedHandlerPerNs(String str) {
+    Map<String, Integer> handlersPerNsMap = new HashMap<>();
+    if (str != null) {
+      String[] tmpStrs = str.split(", ");
+      for(String tmpStr : tmpStrs) {
+        String[] handlersPerNs = tmpStr.split(":");
+        handlersPerNsMap.put(handlersPerNs[0], 
Integer.valueOf(handlersPerNs[1]));
+      }
+    }
+    return handlersPerNsMap;
+  }
+
+  private static Map<String, String> setConfiguration(String str) {
+    Map<String, String> conf = new HashMap<>();
+    if (str != null) {

Review Comment:
   Thank you for your advice, done.



##########
hadoop-hdfs-project/hadoop-hdfs-rbf/src/test/java/org/apache/hadoop/hdfs/server/federation/fairness/TestRouterHandlersFairness.java:
##########
@@ -308,4 +375,28 @@ private void innerCalls(URI address, int numOps, boolean 
isConcurrent,
       overloadException.get();
     }
   }
+
+  private static Map<String, Integer> expectedHandlerPerNs(String str) {
+    Map<String, Integer> handlersPerNsMap = new HashMap<>();
+    if (str != null) {
+      String[] tmpStrs = str.split(", ");
+      for(String tmpStr : tmpStrs) {
+        String[] handlersPerNs = tmpStr.split(":");
+        handlersPerNsMap.put(handlersPerNs[0], 
Integer.valueOf(handlersPerNs[1]));
+      }
+    }
+    return handlersPerNsMap;
+  }
+
+  private static Map<String, String> setConfiguration(String str) {
+    Map<String, String> conf = new HashMap<>();
+    if (str != null) {
+      String[] tmpStrs = str.split(", ");
+      for(String tmpStr : tmpStrs) {
+        String[] configKV = tmpStr.split("=");
+        conf.put(configKV[0], configKV[1]);

Review Comment:
   done.



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to