You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
**What changed?**
Introduce a `PollerGroupsInfo` message carrying a monotonically
increasing `version` alongside the poller groups, so the SDK can ignore
stale snapshots that arrive out of order (e.g. after polls are cancelled
during cell migration).
Deprecate the repeated `poller_group_infos` fields in favor of the new
`poller_groups_info` field on `DescribeNamespaceResponse` and the Poll
Workflow/Activity/Nexus TaskQueue responses.
**Why?**
The server sends poller-group assignment info to the SDK via poll
responses. During cell migration, the server cancels in-flight polls and
returns updated poller-group info, but responses can arrive out of order
— a stale snapshot can land after a fresh one and overwrite it.
Attaching a monotonically increasing `version` lets the SDK ignore any
snapshot that isn't newer than the one it has already applied,
preventing stale overwrites.
**Breaking changes**
None. New fields use fresh field numbers (no reuse), and the old
`poller_group_infos` fields are only marked `[deprecated = true]` —
still fully wire-compatible. `buf breaking` against `main` passes clean.
Consumers referencing the deprecated fields will see deprecation
warnings but will not break.
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: openapi/openapiv2.json
+29-2Lines changed: 29 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -15242,7 +15242,11 @@
15242
15242
"type": "object",
15243
15243
"$ref": "#/definitions/v1PollerGroupInfo"
15244
15244
},
15245
-
"description": "The initial info that client should use for poller group assignment. This information is\nupdated through poll response. Client is supposed to use the info received in the latest\npoll response."
15245
+
"description": "Deprecated. Use `poller_groups_info` instead, which carries a version so the client can\nignore stale updates.\nThe initial info that client should use for poller group assignment. This information is\nupdated through poll response. Client is supposed to use the info received in the latest\npoll response."
15246
+
},
15247
+
"pollerGroupsInfo": {
15248
+
"$ref": "#/definitions/v1PollerGroupsInfo",
15249
+
"description": "The initial, versioned info that client should use for poller group assignment. This\ninformation is updated through poll responses. Client is supposed to use the info with the\nhighest version it has received."
15246
15250
}
15247
15251
}
15248
15252
},
@@ -17943,7 +17947,11 @@
17943
17947
"type": "object",
17944
17948
"$ref": "#/definitions/v1PollerGroupInfo"
17945
17949
},
17946
-
"description": "The weighted list of poller groups IDs that client should use for future polls to this task\nqueue. Client is expected to:\n 1. Maintain minimum number of pollers no less than the number of groups.\n 2. Try to assign the next poll to a group without any pending polls,\n 3. If every group has some pending polls, assign the next poll to a group randomly\n according to the weights."
17950
+
"description": "Deprecated. Use `poller_groups_info` instead, which carries a version so the client can\nignore stale updates.\nThe weighted list of poller groups IDs that client should use for future polls to this task\nqueue. Client is expected to:\n 1. Maintain minimum number of pollers no less than the number of groups.\n 2. Try to assign the next poll to a group without any pending polls,\n 3. If every group has some pending polls, assign the next poll to a group randomly\n according to the weights."
17951
+
},
17952
+
"pollerGroupsInfo": {
17953
+
"$ref": "#/definitions/v1PollerGroupsInfo",
17954
+
"description": "The weighted, versioned list of poller groups IDs that client should use for future polls to\nthis task queue. Client should ignore this if it has already applied a snapshot with a\nversion greater than or equal to `poller_groups_info.version`. Client is expected to:\n 1. Maintain minimum number of pollers no less than the number of groups.\n 2. Try to assign the next poll to a group without any pending polls,\n 3. If every group has some pending polls, assign the next poll to a group randomly\n according to the weights."
17947
17955
}
17948
17956
}
17949
17957
},
@@ -17959,6 +17967,25 @@
17959
17967
}
17960
17968
}
17961
17969
},
17970
+
"v1PollerGroupsInfo": {
17971
+
"type": "object",
17972
+
"properties": {
17973
+
"version": {
17974
+
"type": "string",
17975
+
"format": "int64",
17976
+
"description": "Monotonically increasing version of this snapshot. A client should ignore any snapshot whose\nversion is not greater than the one it last applied."
17977
+
},
17978
+
"pollerGroups": {
17979
+
"type": "array",
17980
+
"items": {
17981
+
"type": "object",
17982
+
"$ref": "#/definitions/v1PollerGroupInfo"
17983
+
},
17984
+
"description": "The weighted list of poller groups the client should use for future polls to this task queue."
17985
+
}
17986
+
},
17987
+
"description": "A versioned snapshot of the poller groups the client should use for future polls to a task\nqueue. The version is monotonically increasing so that a client can ignore a snapshot that is\nolder than the one it has already applied."
0 commit comments