gszadovszky commented on code in PR #3351:
URL: https://github.com/apache/parquet-java/pull/3351#discussion_r2459145581
##########
parquet-hadoop/src/main/java/org/apache/parquet/hadoop/InternalParquetRecordWriter.java:
##########
@@ -140,8 +140,9 @@ public void close() throws IOException,
InterruptedException {
}
finalMetadata.putAll(finalWriteContext.getExtraMetaData());
parquetFileWriter.end(finalMetadata);
+ AutoCloseables.uncheckedClose(parquetFileWriter);
Review Comment:
`parquetFileWriter.end(Map<String, String>)` invokes
`parquetFileWriter.close()`, so this call is not necessary. Why we added the
`close()` call to `finally` to ensure the related buffers are freed (required
for direct memory handling).
Maybe introduce a similar logic of having an `aborted` flag in
`ParquetFileWriter` just like we have done it for `InternalParquetRecordWriter`.
--
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]