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

Fix potential file leak in ES816BinaryQuantizedVectorsWriter #120014

Merged
merged 8 commits into from
Jan 14, 2025

Conversation

iverase
Copy link
Contributor

@iverase iverase commented Jan 11, 2025

We are creating tmp files that might not get closed if an exception happens just after it. This PR makes sure all errors are handle properly and files are getting closed and deleted.

fixes #119981

@iverase iverase requested a review from benwtrent January 11, 2025 10:31
@iverase iverase changed the title Fix potential file leak on ES816BinaryQuantizedVectorsWriter Fix potential file leak in ES816BinaryQuantizedVectorsWriter Jan 11, 2025
@elasticsearchmachine elasticsearchmachine added the Team:Search Relevance Meta label for the Search Relevance team in Elasticsearch label Jan 11, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-search-relevance (Team:Search Relevance)

@elasticsearchmachine
Copy link
Collaborator

Hi @iverase, I've created a changelog YAML for you.

@iverase
Copy link
Contributor Author

iverase commented Jan 13, 2025

Ok, I rework it so we don't close twice the same file.

@iverase iverase added the auto-backport Automatically create backport pull requests when merged label Jan 14, 2025
@iverase iverase merged commit 4b52cf4 into elastic:main Jan 14, 2025
16 checks passed
@iverase iverase deleted the BinaryQuantizedVectorsWriter branch January 14, 2025 07:25
@elasticsearchmachine
Copy link
Collaborator

💔 Backport failed

Status Branch Result
8.x Commit could not be cherrypicked due to conflicts
8.17 Commit could not be cherrypicked due to conflicts
8.16 Commit could not be cherrypicked due to conflicts

You can use sqren/backport to manually backport by running backport --upstream elastic/elasticsearch --pr 120014

iverase added a commit to iverase/elasticsearch that referenced this pull request Jan 14, 2025
…lastic#120014)

We are creating tmp files that might not get closed if an exception happens just after it. This commit makes sure all
errors are handle properly and files are getting closed and deleted.
# Conflicts:
#	muted-tests.yml
iverase added a commit to iverase/elasticsearch that referenced this pull request Jan 14, 2025
…lastic#120014)

We are creating tmp files that might not get closed if an exception happens just after it. This commit makes sure all
errors are handle properly and files are getting closed and deleted.
# Conflicts:
#	muted-tests.yml
iverase added a commit to iverase/elasticsearch that referenced this pull request Jan 14, 2025
…#120014)

We are creating tmp files that might not get closed if an exception happens just after it. This commit makes sure all
errors are handle properly and files are getting closed and deleted.
# Conflicts:
#	muted-tests.yml
elasticsearchmachine pushed a commit that referenced this pull request Jan 14, 2025
…120014) (#120089)

We are creating tmp files that might not get closed if an exception happens just after it. This commit makes sure all
errors are handle properly and files are getting closed and deleted.
# Conflicts:
#	muted-tests.yml
elasticsearchmachine pushed a commit that referenced this pull request Jan 14, 2025
#120091)

We are creating tmp files that might not get closed if an exception happens just after it. This commit makes sure all
errors are handle properly and files are getting closed and deleted.
# Conflicts:
#	muted-tests.yml
elasticsearchmachine pushed a commit that referenced this pull request Jan 14, 2025
…120014) (#120090)

We are creating tmp files that might not get closed if an exception happens just after it. This commit makes sure all
errors are handle properly and files are getting closed and deleted.
# Conflicts:
#	muted-tests.yml
martijnvg pushed a commit to martijnvg/elasticsearch that referenced this pull request Jan 14, 2025
…#120014)

We are creating tmp files that might not get closed if an exception happens just after it. This commit makes sure all
errors are handle properly and files are getting closed and deleted.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Automatically create backport pull requests when merged backport pending >bug :Search Relevance/Search Catch all for Search Relevance Team:Search Relevance Meta label for the Search Relevance team in Elasticsearch v8.16.4 v8.17.2 v8.18.0 v9.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[CI] ES816HnswBinaryQuantizedVectorsFormatTests testRandomExceptions failing
4 participants