nicoloboschi commented on a change in pull request #2469:
URL: https://github.com/apache/bookkeeper/pull/2469#discussion_r528791846



##########
File path: 
bookkeeper-server/src/main/java/org/apache/bookkeeper/meta/zk/ZKMetadataDriverBase.java
##########
@@ -60,12 +60,16 @@
 
     protected static final String SCHEME = "zk";
 
-    public static String getZKServersFromServiceUri(URI uri) {
-        return uri.getAuthority().replace(";", ",");
+    public static String getZKServersFromServiceUri(URI uri) throws 
IllegalArgumentException {
+        String authority = uri.getAuthority();
+        if (authority == null) {
+            throw new IllegalArgumentException("Invalid metadata service URI 
format: " + uri);
+        }
+        return authority.replace(";", ",");
     }
 
     @SuppressWarnings("deprecation")
-    public static String resolveZkServers(AbstractConfiguration<?> conf) {
+    public static String resolveZkServers(AbstractConfiguration<?> conf) 
throws IllegalArgumentException {

Review comment:
       removed 




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


Reply via email to