Jackie-Jiang commented on code in PR #12056:
URL: https://github.com/apache/pinot/pull/12056#discussion_r1406967710


##########
pinot-spi/src/main/java/org/apache/pinot/spi/env/CommonsConfigurationUtils.java:
##########
@@ -107,11 +106,14 @@ public static 
org.apache.commons.configuration.PropertiesConfiguration fromFile(
       // Explicitly providing the input stream on load bypasses the problem.
       propertiesConfiguration.setFile(file);
       if (file.exists()) {
-        propertiesConfiguration.load(new FileInputStream(file));
+        try (InputStream in = new FileInputStream(file)) {
+          propertiesConfiguration.load(in);
+        } catch (IOException e) {
+          throw new RuntimeException(e);
+        }

Review Comment:
   We don't need to catch here



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


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

Reply via email to