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 Tripped Assertion on Resync Failure during Node Shutdown #71062

Merged
merged 2 commits into from
Mar 31, 2021

Conversation

original-brownbear
Copy link
Member

@original-brownbear original-brownbear commented Mar 30, 2021

We can have a race here where the closed check passes and then we concurrently to
a shard close try to fail the shard also. Previously this was covered by the catch below
the changed code that would just ignore the already-closed exception but with #69949 we're
now forking to the generic pool for this logic and thus have to handle the exception in the
callback as well.

Failed in https://gradle-enterprise.elastic.co/s/5i55v7oeoekxc/tests/:server:internalClusterTest/org.elasticsearch.cluster.routing.PrimaryAllocationIT/testForceStaleReplicaToBePromotedToPrimary?expanded-stacktrace=WyIwLTEiLCIwLTEtMiIsIjAtMS0yLTMiXQ#1 and could fail elsewhere (though it's very unlikely)

We can have a race here where the closed check passes and then we concurrently to
a shard close try to fail the shard also. Previously this was covered by the catch below
the changed code that would just ignore the already-closed exception but with elastic#69949 we're
now forking to the generic pool for this logic and thus have to handle the exception in the
callback as well.
@original-brownbear original-brownbear added >non-issue :Distributed Indexing/Recovery Anything around constructing a new shard, either from a local or a remote source. v8.0.0 v7.13.0 labels Mar 30, 2021
@elasticmachine elasticmachine added the Team:Distributed (Obsolete) Meta label for distributed team (obsolete). Replaced by Distributed Indexing/Coordination. label Mar 30, 2021
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-distributed (Team:Distributed)

@original-brownbear original-brownbear changed the title Fix Tripped Assertion on Resync during Node Shutdown Fix Tripped Assertion on Resync Failure during Node Shutdown Mar 30, 2021
@original-brownbear original-brownbear added v7.12.1 :Distributed Indexing/CRUD A catch all label for issues around indexing, updating and getting a doc by id. Not search. and removed :Distributed Indexing/Recovery Anything around constructing a new shard, either from a local or a remote source. labels Mar 30, 2021
Copy link
Contributor

@DaveCTurner DaveCTurner 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
Copy link
Member Author

Thanks David!

@original-brownbear original-brownbear merged commit 5db1673 into elastic:master Mar 31, 2021
@original-brownbear original-brownbear deleted the fix-test-fail branch March 31, 2021 08:42
original-brownbear added a commit to original-brownbear/elasticsearch that referenced this pull request Mar 31, 2021
We can have a race here where the closed check passes and then we concurrently to
a shard close try to fail the shard also. Previously this was covered by the catch below
the changed code that would just ignore the already-closed exception but with elastic#69949 we're
now forking to the generic pool for this logic and thus have to handle the exception in the
callback as well.
original-brownbear added a commit to original-brownbear/elasticsearch that referenced this pull request Mar 31, 2021
We can have a race here where the closed check passes and then we concurrently to
a shard close try to fail the shard also. Previously this was covered by the catch below
the changed code that would just ignore the already-closed exception but with elastic#69949 we're
now forking to the generic pool for this logic and thus have to handle the exception in the
callback as well.
original-brownbear added a commit that referenced this pull request Mar 31, 2021
We can have a race here where the closed check passes and then we concurrently to
a shard close try to fail the shard also. Previously this was covered by the catch below
the changed code that would just ignore the already-closed exception but with #69949 we're
now forking to the generic pool for this logic and thus have to handle the exception in the
callback as well.
original-brownbear added a commit that referenced this pull request Mar 31, 2021
We can have a race here where the closed check passes and then we concurrently to
a shard close try to fail the shard also. Previously this was covered by the catch below
the changed code that would just ignore the already-closed exception but with #69949 we're
now forking to the generic pool for this logic and thus have to handle the exception in the
callback as well.
@original-brownbear original-brownbear restored the fix-test-fail branch April 18, 2023 21:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Distributed Indexing/CRUD A catch all label for issues around indexing, updating and getting a doc by id. Not search. >non-issue Team:Distributed (Obsolete) Meta label for distributed team (obsolete). Replaced by Distributed Indexing/Coordination. v7.12.1 v7.13.0 v8.0.0-alpha1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants