Fix distributed bookmark queue resume race#7419
Draft
sfmskywalker with Copilot wants to merge 3 commits into
Draft
Fix distributed bookmark queue resume race#7419sfmskywalker with Copilot wants to merge 3 commits into
sfmskywalker with Copilot wants to merge 3 commits into
Conversation
Agent-Logs-Url: https://github.com/elsa-workflows/elsa-core/sessions/a518907b-9fca-460b-a81c-fff600642fa2 Co-authored-by: sfmskywalker <938393+sfmskywalker@users.noreply.github.com>
Agent-Logs-Url: https://github.com/elsa-workflows/elsa-core/sessions/a518907b-9fca-460b-a81c-fff600642fa2 Co-authored-by: sfmskywalker <938393+sfmskywalker@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix issue with parent workflow not resuming after child finishes
Fix distributed bookmark queue resume race
Apr 25, 2026
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.
Purpose
Prevent parent workflows from remaining suspended after completed child workflows in distributed runtimes.
Scope
Select one primary concern:
Description
Problem
DispatchWorkflow(WaitForCompletion = true)can lose the bookmark queue wake-up in multi-node deployments when the signaled node cannot acquire the distributed queue lock. With the previous 1-minute default purge TTL, the queued resume item could be deleted before the next retry sweep.Solution
Retry on lock miss
DistributedBookmarkQueueWorkernow re-signals after a short delay when the distributed lock is unavailable.Safer purge window
1 minuteto1 hour.Regression coverage
Verification
Reviewers can verify the behavior through the added unit tests and by inspecting the distributed worker lock-miss path.
Steps:
Elsa.Workflows.Runtime.UnitTests.DistributedBookmarkQueueWorkerTests.BookmarkQueuePurgeOptionsTests.Expected outcome:
Queued bookmark resume items are retried after distributed lock contention and are not purged before normal retry windows.
Screenshots / Recordings (if applicable)
N/A
Commit Convention
We recommend using conventional commit prefixes:
fix:– Bug fixes (behavior change)feat:– New featuresrefactor:– Code changes without behavior changedocs:– Documentation updateschore:– Maintenance, tooling, or dependency updatestest:– Test additions or modificationsClear commit messages make reviews easier and history more meaningful.
Checklist