Add eager standalone activity start API - #876
Open
wenlong-gu wants to merge 1 commit into
Open
wenlong-gu wants to merge 1 commit into
wenlong-gu wants to merge 1 commit into
Conversation
|
Wenlong Gu seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
This was referenced Oct 2, 2026
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
The fields are backward-compatible additions using unused tags and an existing message type, with no blocking issues identified.
Review effort: Balanced
Findings: None
What changed in this PR
Adds the public API contract for eager standalone Activity starts, allowing callers to request direct task delivery. Server behavior is deferred to a separate PR.
Changes:
- Adds
request_eager_executionto the start request. - Adds
eager_activity_taskto the response, documented for newly started activities only.
| File | Description |
|---|---|
| temporal/api/workflowservice/v1/request_response.proto | Adds eager-start request and response fields. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Quinn-With-Two-Ns
approved these changes
Oct 2, 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.
Task overview
Part 1 of 3 for ACT-1118, adding eager start for Standalone Activities (SAA).
Today, an SAA start must create the activity, enqueue a dispatch task, send it
through Matching, and wait for a worker poll. This adds queue latency even when
the caller has a ready local worker.
The complete solution lets an eligible
StartActivityExecutionrequest returnthe first Activity task directly in its response. The server persists the
activity before returning that task and skips only the initial Matching dispatch.
For safety, an eager task is returned only for a newly created execution.
Same-request-ID retries and conflicts such as
USE_EXISTINGreturn theexisting execution without re-delivering the task, because Activity code may
have external side effects.
Scope of this PR
Adds the additive public API contract:
StartActivityExecutionRequest.request_eager_executionStartActivityExecutionResponse.eager_activity_taskThere is no runtime server behavior in this PR.
Related PRs
submodule and regenerates the Go API types.
request eligibility, the eager state transition, task construction,
retry/conflict safety, and tests.
Validation
Benchmark context
This contract-only PR has no runtime behavior. The Temporal implementation was
measured locally in an in-process server test cluster over 200 paired runs:
The measurement covers server-side task delivery only; it excludes SDK worker
scheduling, user Activity execution, network latency, and production load.