dramaticlly opened a new pull request, #17931:
URL: https://github.com/apache/iceberg/pull/17931

   `com.fasterxml.jackson.core.JsonGenerator` implements Closeable and this PR 
attempt to close with try-with-resource in existing code base, to allow reuse 
of internal char buffer.  Verified locally with no introduction of double close
   
   Following the existing pattern in 
https://github.com/apache/iceberg/blob/6ee69282ab18ef578243da96ab1e522b654811da/core/src/main/java/org/apache/iceberg/util/JsonUtil.java#L74-L87
   
   
   I also dropped some of `generator.flush()` call because no read of target 
happens within the try block. 
   | Src                                       |                 Read of target 
              | flush() |
   
|-------------------------------------------|:-----------------------------------:|--------:|
   | StreamingOffset.json                      |       outside the body       | 
dropped |
   | HMSTablePropertyHelper.hashOf             | inside the body |    kept |
   | TableMetadataParser.toJson(TableMetadata) |           inside the body      
     |    kept |
   | Table/ViewMetadataParser.internalWrite    | no read                        
     | dropped |
   


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