Repository navigation
Improve ShardLockObtainFailedException message - #134198
Merged
elasticsearchmachine merged 2 commits intoSep 5, 2025
Merged
elasticsearchmachine merged 2 commits into
elasticsearchmachine merged 2 commits into
Conversation
It's unclear whether the age mentioned here is the age of the lock, or just of the detailed state of the lock. This commit clarifies the message.
Collaborator
|
Pinging @elastic/es-distributed-indexing (Team:Distributed Indexing) |
Collaborator
|
Hi @DaveCTurner, I've created a changelog YAML for you. |
ywangd
approved these changes
Sep 5, 2025
| "obtaining shard lock for [%s] timed out after [%dms], lock already held for [%s] with age [%dms]", | ||
| """ | ||
| obtaining shard lock for [%s] timed out after [%dms]; \ | ||
| this shard lock is still held by a different instance of the shard and has been in state [%s] for [%s/%dms]""", |
Member
There was a problem hiding this comment.
different instance
I think this should be true. Just want to explicitly confirm it.
Member
Author
There was a problem hiding this comment.
In practice yes. If it were the same instance of the shard, it wouldn't be trying to acquire a fresh shard lock.
Technically it might not be an IndexShard instance that holds this lock, it could also be one of the processes that deletes unused shard data, but we don't see that happen here and IMO the phrase instance of the shard is sufficiently loosely defined to include those processes too.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
It's unclear whether the age mentioned here is the age of the lock, or
just of the detailed state of the lock. This commit clarifies the
message.