Skip to content

Commit

Permalink
Update backlog_count_hint docstring (#413)
Browse files Browse the repository at this point in the history
  • Loading branch information
Sushisource authored May 29, 2024
1 parent 74f9631 commit 8c57e7b
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 6 deletions.
2 changes: 1 addition & 1 deletion openapi/openapiv2.json
Original file line number Diff line number Diff line change
Expand Up @@ -6569,7 +6569,7 @@
"backlogCountHint": {
"type": "string",
"format": "int64",
"description": "A hint that there are more tasks already present in this task queue. Can be used to\nprioritize draining a sticky queue before polling from a normal queue."
"description": "A hint that there are more tasks already present in this task queue \npartition. Can be used to prioritize draining a sticky queue.\n\nSpecifically, the returned number is the number of tasks remaining in\nthe in-memory buffer for this partition, which is currently capped at\n1000. Because sticky queues only have one partition, this number is \nmore useful when draining them. Normal queues, typically having more than one \npartition, will return a number representing only some portion of the \noverall backlog. Subsequent RPCs may not hit the same partition as \nthis call."
},
"history": {
"$ref": "#/definitions/v1History",
Expand Down
4 changes: 1 addition & 3 deletions openapi/openapiv3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4474,9 +4474,7 @@ components:
format: int32
backlogCountHint:
type: string
description: |-
A hint that there are more tasks already present in this task queue. Can be used to
prioritize draining a sticky queue before polling from a normal queue.
description: "A hint that there are more tasks already present in this task queue \n partition. Can be used to prioritize draining a sticky queue.\n\n Specifically, the returned number is the number of tasks remaining in\n the in-memory buffer for this partition, which is currently capped at\n 1000. Because sticky queues only have one partition, this number is \n more useful when draining them. Normal queues, typically having more than one \n partition, will return a number representing only some portion of the \n overall backlog. Subsequent RPCs may not hit the same partition as \n this call."
history:
allOf:
- $ref: '#/components/schemas/History'
Expand Down
12 changes: 10 additions & 2 deletions temporal/api/workflowservice/v1/request_response.proto
Original file line number Diff line number Diff line change
Expand Up @@ -278,8 +278,16 @@ message PollWorkflowTaskQueueResponse {
int64 started_event_id = 5;
// Starting at 1, the number of attempts to complete this task by any worker.
int32 attempt = 6;
// A hint that there are more tasks already present in this task queue. Can be used to
// prioritize draining a sticky queue before polling from a normal queue.
// A hint that there are more tasks already present in this task queue
// partition. Can be used to prioritize draining a sticky queue.
//
// Specifically, the returned number is the number of tasks remaining in
// the in-memory buffer for this partition, which is currently capped at
// 1000. Because sticky queues only have one partition, this number is
// more useful when draining them. Normal queues, typically having more than one
// partition, will return a number representing only some portion of the
// overall backlog. Subsequent RPCs may not hit the same partition as
// this call.
int64 backlog_count_hint = 7;
// The history for this workflow, which will either be complete or partial. Partial histories
// are sent to workers who have signaled that they are using a sticky queue when completing
Expand Down

0 comments on commit 8c57e7b

Please sign in to comment.