Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Core: Update TableMetadataParser to close streams #11220

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

erik-grepr
Copy link

@erik-grepr erik-grepr commented Sep 27, 2024

Minor try-with-resources tweak to fix an unclosed stream memory leak I encountered.

More specifically, this occurs when the file is Gzipped and file.newStream().read() throws an exception.

The GZIPInputStream constructor calls read on it's input to load the header.

see: https://stackoverflow.com/questions/12552863/correct-idiom-for-managing-multiple-chained-resources-in-try-with-resources-bloc

@github-actions github-actions bot added the core label Sep 27, 2024
@erik-grepr erik-grepr changed the title Update TableMetadataParser to close streams Core: Update TableMetadataParser to close streams Sep 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant