doki23 commented on code in PR #2951:
URL: https://github.com/apache/parquet-java/pull/2951#discussion_r1677056091


##########
parquet-hadoop/src/main/java/org/apache/parquet/hadoop/ParquetFileWriter.java:
##########
@@ -1658,11 +1659,15 @@ public void end(Map<String, String> extraMetaData) 
throws IOException {
 
   @Override
   public void close() throws IOException {
+    if (closed) {
+      return;
+    }
     try (PositionOutputStream temp = out) {
       temp.flush();
       if (crcAllocator != null) {
         crcAllocator.close();
       }
+      closed = true;

Review Comment:
   Putting it in finally block makes it be not retryable.



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