{{ message }}
Repository navigation
Add PollerScalingInfo to poll requests - #887
Open
veeral-patel wants to merge 2 commits into
Open
veeral-patel wants to merge 2 commits into
veeral-patel wants to merge 2 commits into
Conversation
Workers report the poller target of the pool issuing each poll so the server can distribute poller-scaling suggestions fairly across a fleet. Scaling suggestions ride on dispatched tasks and the matcher is FIFO, so a worker's share of suggestions tracks its share of pollers. Growth is therefore proportional to current size, which preserves any imbalance between otherwise identical workers rather than correcting it. With a reported target the server can withhold suggestions that would push a worker further from its share.
This was referenced Oct 20, 2026
Sushisource
reviewed
Oct 20, 2026
Comment on lines
+39
to
+44
Member
There was a problem hiding this comment.
I dunno that this needs to go into detail about the specific motivating problem. Can probably just drop the whole paragraph honestly.
Co-authored-by: Spencer Judge <spencer@temporal.io>
veeral-patel
marked this pull request as ready for review
October 20, 2026 20:11
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.

What
Adds
PollerScalingInfototemporal.api.taskqueue.v1, carrying a single field, and attaches it as field 11 on bothPollWorkflowTaskQueueRequestandPollActivityTaskQueueRequest.Why
Poller scaling suggestions ride on dispatched tasks, and the matcher hands tasks to waiting pollers in FIFO order. So a worker's share of suggestions tracks its share of pollers: growth is proportional to current size, in both directions. The equilibrium is degenerate — any imbalance between otherwise identical workers is preserved and amplified rather than corrected.
Measured on three identically configured workers, the activity poller split landed at 74/12/14 percent, with a different winner each run.
Fixing that needs the server to know how each worker's pool compares to the fleet, and the poller target is the one number that makes the comparison possible.
0means unknown (for example a fixed-size pool), and the server applies no share-based fairness to such a worker — so SDKs that never populate this are unaffected.Notes
max_slotsto weight share by execution capacity; it was dropped to keep the wire contract to one number.Stacked on this
temporalio/sdk-go— reports the target on each polltemporalio/temporal— consumes it to spread suggestions across the fleet