ayushtkn commented on a change in pull request #1699: HDFS-14962. RBF: 
ConnectionPool#newConnection() error log wrong protocol class
URL: https://github.com/apache/hadoop/pull/1699#discussion_r344110373
 
 

 ##########
 File path: 
hadoop-hdfs-project/hadoop-hdfs-rbf/src/test/java/org/apache/hadoop/hdfs/server/federation/router/TestConnectionManager.java
 ##########
 @@ -301,4 +302,15 @@ public void testConfigureConnectionActiveRatio() throws 
IOException {
 
     tmpConnManager.close();
   }
+
+  @Test
+  public void testUnsupportedProtoExceptionMsg() throws Exception {
+    LambdaTestUtils.intercept(IllegalStateException.class,
+        "Unsupported protocol for connection to NameNode: "
+            + TestConnectionManager.class.getName(),
+        () -> ConnectionPool.newConnection(conf, TEST_NN_ADDRESS, TEST_USER1,
+            TestConnectionManager.class));
+  }
+
+  interface UnsupportedProto { }
 
 Review comment:
   This line now is not required interface UnsupportedProto { } we can remove 
it.
   Apart LGTM

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

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

Reply via email to