-
Notifications
You must be signed in to change notification settings - Fork 25.6k
Fix test - wait for other threads before throwing the exception #124386
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
Conversation
|
Pinging @elastic/es-search-foundations (Team:Search Foundations) |
original-brownbear
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, what do you think about my suggestion though to simplify this slightly? :)
|
|
||
| // When the search request executes, block all shards except 1. | ||
| final List<SearchShardBlockingPlugin> searchShardBlockingPlugins = initSearchShardBlockingPlugin(); | ||
| AtomicBoolean letOneShardProceed = new AtomicBoolean(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we could make this slightly simpler by using a nAtomicReference<CountDownLatch> and then doing something like latch = getAndSet(null); if (latch != null) latch.await to save a variable?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure I understood how it should work. I think it's better to check if this one works and then if it fixes the issues then we can refactor it.
💔 Backport failed
You can use sqren/backport to manually backport by running |
…tic#124386) (cherry picked from commit b9a9784) # Conflicts: # server/src/internalClusterTest/java/org/elasticsearch/search/SearchCancellationIT.java
💚 All backports created successfully
Questions ?Please refer to the Backport tool documentation |
…tic#124386) (cherry picked from commit b9a9784) # Conflicts: # server/src/internalClusterTest/java/org/elasticsearch/search/SearchCancellationIT.java
Fixes #121719