tanishq-chugh commented on code in PR #5404: URL: https://github.com/apache/hive/pull/5404#discussion_r2048773518
########## common/src/java/org/apache/hadoop/hive/common/CompressionUtils.java: ########## @@ -169,30 +169,30 @@ public static List<File> unTar(final String inputFileName, final String outputDi // no sub-directories continue; } - LOG.debug(String.format("Attempting to write output directory %s.", - outputFile.getAbsolutePath())); + LOG.debug("Attempting to write output directory %s.".formatted( + outputFile.getAbsolutePath())); if (!outputFile.exists()) { - LOG.debug(String.format("Attempting to create output directory %s.", - outputFile.getAbsolutePath())); + LOG.debug("Attempting to create output directory %s.".formatted( + outputFile.getAbsolutePath())); if (!outputFile.mkdirs()) { - throw new IllegalStateException(String.format("Couldn't create directory %s.", - outputFile.getAbsolutePath())); + throw new IllegalStateException("Couldn't create directory %s.".formatted( + outputFile.getAbsolutePath())); } } } else { final OutputStream outputFileStream; if (flatten) { File flatOutputFile = new File(outputDir, outputFile.getName()); - LOG.debug(String.format("Creating flat output file %s.", flatOutputFile.getAbsolutePath())); + LOG.debug("Creating flat output file %s.".formatted(flatOutputFile.getAbsolutePath())); outputFileStream = new FileOutputStream(flatOutputFile); } else if (!outputFile.getParentFile().exists()) { - LOG.debug(String.format("Attempting to create output directory %s.", - outputFile.getParentFile().getAbsoluteFile())); + LOG.debug("Attempting to create output directory %s.".formatted( + outputFile.getParentFile().getAbsoluteFile())); if (!outputFile.getParentFile().getAbsoluteFile().mkdirs()) { - throw new IllegalStateException(String.format("Couldn't create directory %s.", - outputFile.getParentFile().getAbsolutePath())); + throw new IllegalStateException("Couldn't create directory %s.".formatted( + outputFile.getParentFile().getAbsolutePath())); } - LOG.debug(String.format("Creating output file %s.", outputFile.getAbsolutePath())); + LOG.debug("Creating output file %s.".formatted(outputFile.getAbsolutePath())); Review Comment: Made changes to use log4 format wherever applicable in [3c521be](https://github.com/apache/hive/pull/5404/commits/3c521be48ade04f17ce3ee69bf588aff0ec8e34a) -- 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: gitbox-unsubscr...@hive.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org For additional commands, e-mail: gitbox-h...@hive.apache.org