smengcl commented on a change in pull request #1305: HDDS-1938. Change omPort 
parameter type from String to int in BasicOzoneFileSystem#createAdapter
URL: https://github.com/apache/hadoop/pull/1305#discussion_r314890276
 
 

 ##########
 File path: 
hadoop-ozone/ozonefs/src/main/java/org/apache/hadoop/fs/ozone/BasicOzoneFileSystem.java
 ##########
 @@ -113,7 +113,7 @@ public void initialize(URI name, Configuration conf) 
throws IOException {
     String remaining = matcher.groupCount() == 3 ? matcher.group(3) : null;
 
     String omHost = null;
-    String omPort = String.valueOf(-1);
+    int omPort = -1;
 
 Review comment:
   I think we should initialize it. Because In a corner case where `remaining` 
is empty, omPort would be uninitialized when reaching line 154 
(createAdapter()). I think that might be an issue.

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