Repository navigation
Conversation
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No actionable issues were found in the reviewed changes.
No open issues 🎉
What changed in this PR
Fixes stalled entity calls by scheduling a continuation when granting a queued lock makes the next request eligible.
Changes:
- Continues processing queued calls from the new lock owner.
- Adds regression coverage for eligible calls, empty queues, and calls from other owners.
- Extracts a shared test helper for running entity sessions.
| File | Description |
|---|---|
| test/DurableTask.Core.Tests/TestTaskEntityDispatcher.cs | Tests continuation behavior and queued-call completion; extracts a session helper. |
| src/DurableTask.Core/TaskEntityDispatcher.cs | Schedules a continuation when queued work becomes eligible after granting a lock. |
Review effort: Balanced
wangbill (YunchuWang)
approved these changes
Dec 4, 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.
After an entity grants a queued lock, a call from the new owner can already be waiting behind it. For example, the caller may have received an earlier lock response before the corresponding checkpoint failed. The dispatcher stopped at the lock request and did not schedule another turn, leaving that call stuck until some other message arrived.
Send a continuation when granting the lock makes the next queued request eligible. An empty queue or a request from another caller does not cause a continuation.
The regression test reproduces the missing continuation on main, then follows the emitted continuation to verify that the waiting call executes and returns its result. It also covers empty queues and calls blocked by a different lock owner. All 27
TestTaskEntityDispatchertests pass on both net8.0 and net48.