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

GH-1701: fix double close of ParquetFileWriter #2958

Closed

Conversation

naude-r
Copy link

@naude-r naude-r commented Jul 17, 2024

Rationale for this change

ParquetFileWriter::close can be called multiple times (end -> close and InternalParquetRecordWriter::close via AutoCloseables.uncheckedClose). this causes an exception to be generated on the 2nd close.

What changes are included in this PR?

Make ParquetFileWriter::close safe to be called multiple times.

Are these changes tested?

Yes.

Are there any user-facing changes?

No.

Closes #1701

…nd InternalParquetRecordWriter::close via AutoCloseables.uncheckedClose). this

causes an exception to be generated on the 2nd close.

fixes apache#1701
@Fokko
Copy link
Contributor

Fokko commented Jul 17, 2024

@naude-r I think this is a duplicate of #2951

@Fokko
Copy link
Contributor

Fokko commented Jul 17, 2024

@naude-r Thanks for raising this PR. Can you elaborate on where you encountered this issue?

@naude-r
Copy link
Author

naude-r commented Jul 17, 2024

@naude-r I think this is a duplicate of #2951

thank you....did not notice the other PR. this can be closed in favor of that.

@naude-r
Copy link
Author

naude-r commented Jul 17, 2024

@naude-r Thanks for raising this PR. Can you elaborate on where you encountered this issue?

since upgrading to 1.14 we've noticed this when performing a ParquetWriter::close. only reason for upgrading was due to our security scanner highlighting an issue.

@wgtmac
Copy link
Member

wgtmac commented Jul 24, 2024

Let me close this. Thanks @naude-r and @Fokko!

@wgtmac wgtmac closed this Jul 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ParquetWriter::close sometimes fail
3 participants