steveloughran commented on code in PR #2991:
URL: https://github.com/apache/parquet-java/pull/2991#discussion_r1778974030


##########
parquet-hadoop/src/main/java/org/apache/parquet/hadoop/util/HadoopPositionOutputStream.java:
##########
@@ -62,7 +64,9 @@ public void flush() throws IOException {
   @Override
   public void close() throws IOException {
     try (FSDataOutputStream fdos = wrapped) {

Review Comment:
   looking at this more, while it does guarantee wrapped.close() is called and 
is very pretty, there's a risk that if hflush() raises an exception then 
anything raised by wrapped.close() is lost. 
   when working to s3, it's that close() where the write to S3 takes place and 
is where the more important failures are likely to be raised.
   It might be best to catch and log the hflush failure and always call 
wrapped.close()



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