You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@inlong.apache.org by GitBox <gi...@apache.org> on 2022/09/02 03:28:55 UTC

[GitHub] [inlong] xuesongxs opened a new pull request, #5768: [INLONG-5767][Sort] Fix IOUtils interface is incompatible in jdk17

xuesongxs opened a new pull request, #5768:
URL: https://github.com/apache/inlong/pull/5768

   Fixes #5767 


-- 
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: commits-unsubscribe@inlong.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [inlong] thesumery commented on a diff in pull request #5768: [INLONG-5767][Sort] Fix IOUtils interface is incompatible in jdk17

Posted by GitBox <gi...@apache.org>.
thesumery commented on code in PR #5768:
URL: https://github.com/apache/inlong/pull/5768#discussion_r961332472


##########
inlong-sort/sort-end-to-end-tests/src/test/java/org/apache/inlong/sort/tests/utils/FlinkContainerTestEnv.java:
##########
@@ -293,8 +294,11 @@ private String constructDistJar(Path... jars) throws IOException {
             for (Path jar : jars) {
                 try (InputStream is = new FileInputStream(jar.toFile())) {
                     jos.putNextEntry(new JarEntry("lib/" + jar.getFileName().toString()));
-                    jos.write(IOUtils.readNBytes(is, is.available()));
+                    jos.write(IOUtils.toByteArray(is));
+                    is.close();

Review Comment:
   is.close() is useless , try with resource will auto close it.



-- 
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: commits-unsubscribe@inlong.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [inlong] dockerzhang merged pull request #5768: [INLONG-5767][Sort] Fix IOUtils interface is incompatible in JDK 17

Posted by GitBox <gi...@apache.org>.
dockerzhang merged PR #5768:
URL: https://github.com/apache/inlong/pull/5768


-- 
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: commits-unsubscribe@inlong.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org