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 remaining leaked SearchResponse issues in :server:integTests #102896

Conversation

original-brownbear
Copy link
Member

This should be the last round for this module, found these using a prototype that has SearchResponse ref-counted already.

Tried to keep it as simple as possible, using assertResponse where possible. When it wasn't reasonable to use it or otherwise not the best option:

  • try-finally in case variables got assigned
  • shortened lots of hit-count assertions
  • used dec-ref before reassigning variables in a couple tests that reused the same var for the search response in a loop, not the nicest but definitely the easiest to review option

This should be the last round for this module, found these using a prototype
that has `SearchResponse` ref-counted already.
@original-brownbear original-brownbear added >test Issues or PRs that are addressing/adding tests :Search/Search Search-related issues that do not fall into other categories labels Dec 2, 2023
@elasticsearchmachine elasticsearchmachine added v8.12.0 Team:Search Meta label for search team labels Dec 2, 2023
@elasticsearchmachine
Copy link
Collaborator

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

original-brownbear added a commit to original-brownbear/elasticsearch that referenced this pull request Dec 2, 2023
Same as elastic#102896, handling almost all of the remaining spots (just a handful of tricky ones left that I'll
open a separate PR for).
Copy link
Contributor

@iverase iverase left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

original-brownbear added a commit that referenced this pull request Dec 4, 2023
Same as #102896, handling almost all of the remaining spots (just a handful of tricky ones left that I'll
open a separate PR for).
@original-brownbear original-brownbear merged commit 143f420 into elastic:main Dec 4, 2023
15 checks passed
@original-brownbear original-brownbear deleted the fix-remaining-search-integ-tests branch December 4, 2023 18:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Search/Search Search-related issues that do not fall into other categories Team:Search Meta label for search team >test Issues or PRs that are addressing/adding tests v8.12.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants