StevenLuMT commented on code in PR #3158:
URL: https://github.com/apache/bookkeeper/pull/3158#discussion_r930144193


##########
bookkeeper-common/src/main/java/org/apache/bookkeeper/common/net/ServiceURI.java:
##########
@@ -215,21 +249,21 @@ public static ServiceURI create(URI uri) {
     }
 
     private static String validateHostName(String serviceName, String 
hostname) {
-        String[] parts = hostname.split(":");
-        if (parts.length >= 3) {
+        URI uri = null;
+        try {
+            uri = URI.create("dummyscheme://" + hostname);

Review Comment:
   `uri = URI.create("dummyscheme://" + hostname);`
   I think testcase doesn't cover this



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

Reply via email to