Cosss7 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_r344097267
########## File path: hadoop-hdfs-project/hadoop-hdfs-rbf/src/test/java/org/apache/hadoop/hdfs/server/federation/router/TestConnectionManager.java ########## @@ -301,4 +301,16 @@ public void testConfigureConnectionActiveRatio() throws IOException { tmpConnManager.close(); } + + @Test + public void testUnsupportedProtoExceptionMsg() throws IOException { + exceptionRule.expect(IllegalStateException.class); + exceptionRule + .expectMessage("Unsupported protocol for connection to NameNode: " + + UnsupportedProto.class.getName()); + ConnectionPool.newConnection(conf, TEST_NN_ADDRESS, TEST_USER1, + UnsupportedProto.class); + } + + interface UnsupportedProto { } Review comment: Got it. ---------------------------------------------------------------- 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: us...@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: common-issues-h...@hadoop.apache.org