From f083ed644049345883c207e39467f0078bf525cc Mon Sep 17 00:00:00 2001 From: Kannan Rajah Date: Mon, 6 Jul 2026 20:06:08 -0700 Subject: [PATCH 1/8] Add rate_limiting_active field to TaskQueueStats When a task queue's whole-queue rate limit is blocking dispatches, auto-scaling systems should suppress scale-up since more workers cannot increase throughput. This boolean surfaces that state. Co-Authored-By: Claude Opus 4.6 --- openapi/openapiv2.json | 4 ++++ openapi/openapiv3.yaml | 9 +++++++++ temporal/api/taskqueue/v1/message.proto | 7 +++++++ 3 files changed, 20 insertions(+) diff --git a/openapi/openapiv2.json b/openapi/openapiv2.json index 7e5e01174..eb50c67d4 100644 --- a/openapi/openapiv2.json +++ b/openapi/openapiv2.json @@ -19569,6 +19569,10 @@ "type": "number", "format": "float", "description": "The approximate tasks per second dispatched from the task queue, averaging the last 30 seconds. These includes\ntasks whether or not they were added to/dispatched from the backlog or they were dispatched immediately without\ngoing to the backlog (sync-matched).\n\nThe difference between `tasks_add_rate` and `tasks_dispatch_rate` is a reliable metric for the rate at which\nbacklog grows/shrinks.\n\nNote: the actual tasks delivered to the workers may significantly be higher than the numbers reported by\ntasks_dispatch_rate, because:\n- Tasks can be sent to workers without going to the task queue. This is called Eager dispatch. Eager dispatch is\n enable for activities by default in the latest SDKs.\n- Tasks going to Sticky queue are not accounted for. Note that, typically, only the first workflow task of each\n workflow goes to a normal queue, and the rest workflow tasks go to the Sticky queue associated with a specific\n worker instance." + }, + "rateLimitingActive": { + "type": "boolean", + "description": "Whether the task queue's whole-queue rate limit is currently blocking dispatches. When true, adding more\nworkers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is\nuseful for auto-scaling systems to avoid unnecessary scale-up.\n\nThis reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle\nindividual tenants while other tenants can still benefit from additional workers." } }, "description": "TaskQueueStats contains statistics about task queue backlog and activity.\n\nFor workflow task queue type, this result is partial because tasks sent to sticky queues are not included. Read\ncomments above each metric to understand the impact of sticky queue exclusion on that metric accuracy." diff --git a/openapi/openapiv3.yaml b/openapi/openapiv3.yaml index 66b86d663..b86112690 100644 --- a/openapi/openapiv3.yaml +++ b/openapi/openapiv3.yaml @@ -17293,6 +17293,15 @@ components: workflow goes to a normal queue, and the rest workflow tasks go to the Sticky queue associated with a specific worker instance. format: float + rateLimitingActive: + type: boolean + description: |- + Whether the task queue's whole-queue rate limit is currently blocking dispatches. When true, adding more + workers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is + useful for auto-scaling systems to avoid unnecessary scale-up. + + This reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle + individual tenants while other tenants can still benefit from additional workers. description: |- TaskQueueStats contains statistics about task queue backlog and activity. diff --git a/temporal/api/taskqueue/v1/message.proto b/temporal/api/taskqueue/v1/message.proto index 358b9430c..8d990d3e5 100644 --- a/temporal/api/taskqueue/v1/message.proto +++ b/temporal/api/taskqueue/v1/message.proto @@ -143,6 +143,13 @@ message TaskQueueStats { // workflow goes to a normal queue, and the rest workflow tasks go to the Sticky queue associated with a specific // worker instance. float tasks_dispatch_rate = 4; + // Whether the task queue's whole-queue rate limit is currently blocking dispatches. When true, adding more + // workers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is + // useful for auto-scaling systems to avoid unnecessary scale-up. + // + // This reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle + // individual tenants while other tenants can still benefit from additional workers. + bool rate_limiting_active = 5; } // Deprecated. Use `InternalTaskQueueStatus`. This is kept until `DescribeTaskQueue` supports legacy behavior. From 2e8080c0a4a72cf4465ca53573d2bc49c07cb6ae Mon Sep 17 00:00:00 2001 From: Kannan Rajah Date: Mon, 6 Jul 2026 22:08:17 -0700 Subject: [PATCH 2/8] Clarify per-key rate limit comment and add blank line before field Co-Authored-By: Claude Opus 4.6 --- temporal/api/taskqueue/v1/message.proto | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/temporal/api/taskqueue/v1/message.proto b/temporal/api/taskqueue/v1/message.proto index 8d990d3e5..8c26c131d 100644 --- a/temporal/api/taskqueue/v1/message.proto +++ b/temporal/api/taskqueue/v1/message.proto @@ -143,12 +143,14 @@ message TaskQueueStats { // workflow goes to a normal queue, and the rest workflow tasks go to the Sticky queue associated with a specific // worker instance. float tasks_dispatch_rate = 4; + // Whether the task queue's whole-queue rate limit is currently blocking dispatches. When true, adding more // workers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is // useful for auto-scaling systems to avoid unnecessary scale-up. // // This reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle - // individual tenants while other tenants can still benefit from additional workers. + // individual tenants, but other tenants can still benefit from additional workers, so per-key limiting + // alone does not set this flag. bool rate_limiting_active = 5; } From c40f0ea52e148a5cc6c9df47463a5cff4a5eaad8 Mon Sep 17 00:00:00 2001 From: Kannan Rajah Date: Mon, 6 Jul 2026 22:10:43 -0700 Subject: [PATCH 3/8] Use 'keys' instead of 'tenants' in rate limit comment Co-Authored-By: Claude Opus 4.6 --- temporal/api/taskqueue/v1/message.proto | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/temporal/api/taskqueue/v1/message.proto b/temporal/api/taskqueue/v1/message.proto index 8c26c131d..06f31ab99 100644 --- a/temporal/api/taskqueue/v1/message.proto +++ b/temporal/api/taskqueue/v1/message.proto @@ -149,8 +149,8 @@ message TaskQueueStats { // useful for auto-scaling systems to avoid unnecessary scale-up. // // This reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle - // individual tenants, but other tenants can still benefit from additional workers, so per-key limiting - // alone does not set this flag. + // individual keys, but other keys can still benefit from additional workers, so per-key limiting alone + // does not set this flag. bool rate_limiting_active = 5; } From 93f089b315856b75b912c15d79640a0d227a010b Mon Sep 17 00:00:00 2001 From: Kannan Rajah Date: Mon, 6 Jul 2026 22:27:35 -0700 Subject: [PATCH 4/8] Regenerate OpenAPI docs Co-Authored-By: Claude Opus 4.6 --- openapi/openapiv2.json | 2 +- openapi/openapiv3.yaml | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/openapi/openapiv2.json b/openapi/openapiv2.json index eb50c67d4..03ce2c1f4 100644 --- a/openapi/openapiv2.json +++ b/openapi/openapiv2.json @@ -19572,7 +19572,7 @@ }, "rateLimitingActive": { "type": "boolean", - "description": "Whether the task queue's whole-queue rate limit is currently blocking dispatches. When true, adding more\nworkers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is\nuseful for auto-scaling systems to avoid unnecessary scale-up.\n\nThis reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle\nindividual tenants while other tenants can still benefit from additional workers." + "description": "Whether the task queue's whole-queue rate limit is currently blocking dispatches. When true, adding more\nworkers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is\nuseful for auto-scaling systems to avoid unnecessary scale-up.\n\nThis reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle\nindividual keys, but other keys can still benefit from additional workers, so per-key limiting alone\ndoes not set this flag." } }, "description": "TaskQueueStats contains statistics about task queue backlog and activity.\n\nFor workflow task queue type, this result is partial because tasks sent to sticky queues are not included. Read\ncomments above each metric to understand the impact of sticky queue exclusion on that metric accuracy." diff --git a/openapi/openapiv3.yaml b/openapi/openapiv3.yaml index b86112690..8770beeeb 100644 --- a/openapi/openapiv3.yaml +++ b/openapi/openapiv3.yaml @@ -17301,7 +17301,8 @@ components: useful for auto-scaling systems to avoid unnecessary scale-up. This reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle - individual tenants while other tenants can still benefit from additional workers. + individual keys, but other keys can still benefit from additional workers, so per-key limiting alone + does not set this flag. description: |- TaskQueueStats contains statistics about task queue backlog and activity. From b50e8e39aefce9407101b89aca7d1054612cb5d8 Mon Sep 17 00:00:00 2001 From: Kannan Rajah Date: Tue, 7 Jul 2026 11:02:28 -0700 Subject: [PATCH 5/8] Document instantaneous semantics of rate_limiting_active Co-Authored-By: Claude Opus 4.6 --- openapi/openapiv2.json | 2 +- openapi/openapiv3.yaml | 4 ++++ temporal/api/taskqueue/v1/message.proto | 4 ++++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/openapi/openapiv2.json b/openapi/openapiv2.json index 03ce2c1f4..e1c382c46 100644 --- a/openapi/openapiv2.json +++ b/openapi/openapiv2.json @@ -19572,7 +19572,7 @@ }, "rateLimitingActive": { "type": "boolean", - "description": "Whether the task queue's whole-queue rate limit is currently blocking dispatches. When true, adding more\nworkers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is\nuseful for auto-scaling systems to avoid unnecessary scale-up.\n\nThis reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle\nindividual keys, but other keys can still benefit from additional workers, so per-key limiting alone\ndoes not set this flag." + "description": "Whether the task queue's whole-queue rate limit is currently blocking dispatches. When true, adding more\nworkers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is\nuseful for auto-scaling systems to avoid unnecessary scale-up.\n\nThis reflects instantaneous state at the time of the query. If worker throughput is close to the rate\nlimit, this value may alternate between true and false across successive queries. Consumers should\napply their own smoothing or hysteresis to avoid oscillating scaling decisions.\n\nThis reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle\nindividual keys, but other keys can still benefit from additional workers, so per-key limiting alone\ndoes not set this flag." } }, "description": "TaskQueueStats contains statistics about task queue backlog and activity.\n\nFor workflow task queue type, this result is partial because tasks sent to sticky queues are not included. Read\ncomments above each metric to understand the impact of sticky queue exclusion on that metric accuracy." diff --git a/openapi/openapiv3.yaml b/openapi/openapiv3.yaml index 8770beeeb..87f31b546 100644 --- a/openapi/openapiv3.yaml +++ b/openapi/openapiv3.yaml @@ -17300,6 +17300,10 @@ components: workers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is useful for auto-scaling systems to avoid unnecessary scale-up. + This reflects instantaneous state at the time of the query. If worker throughput is close to the rate + limit, this value may alternate between true and false across successive queries. Consumers should + apply their own smoothing or hysteresis to avoid oscillating scaling decisions. + This reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle individual keys, but other keys can still benefit from additional workers, so per-key limiting alone does not set this flag. diff --git a/temporal/api/taskqueue/v1/message.proto b/temporal/api/taskqueue/v1/message.proto index 06f31ab99..2fb523aa4 100644 --- a/temporal/api/taskqueue/v1/message.proto +++ b/temporal/api/taskqueue/v1/message.proto @@ -148,6 +148,10 @@ message TaskQueueStats { // workers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is // useful for auto-scaling systems to avoid unnecessary scale-up. // + // This reflects instantaneous state at the time of the query. If worker throughput is close to the rate + // limit, this value may alternate between true and false across successive queries. Consumers should + // apply their own smoothing or hysteresis to avoid oscillating scaling decisions. + // // This reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle // individual keys, but other keys can still benefit from additional workers, so per-key limiting alone // does not set this flag. From a1d7ab96a4bea0e542fc41625c6dd00030eb59e9 Mon Sep 17 00:00:00 2001 From: Kannan Rajah Date: Tue, 7 Jul 2026 11:04:36 -0700 Subject: [PATCH 6/8] Remove redundant 'currently' from rate_limiting_active comment Co-Authored-By: Claude Opus 4.6 --- openapi/openapiv2.json | 2 +- openapi/openapiv3.yaml | 2 +- temporal/api/taskqueue/v1/message.proto | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/openapi/openapiv2.json b/openapi/openapiv2.json index e1c382c46..f60426d40 100644 --- a/openapi/openapiv2.json +++ b/openapi/openapiv2.json @@ -19572,7 +19572,7 @@ }, "rateLimitingActive": { "type": "boolean", - "description": "Whether the task queue's whole-queue rate limit is currently blocking dispatches. When true, adding more\nworkers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is\nuseful for auto-scaling systems to avoid unnecessary scale-up.\n\nThis reflects instantaneous state at the time of the query. If worker throughput is close to the rate\nlimit, this value may alternate between true and false across successive queries. Consumers should\napply their own smoothing or hysteresis to avoid oscillating scaling decisions.\n\nThis reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle\nindividual keys, but other keys can still benefit from additional workers, so per-key limiting alone\ndoes not set this flag." + "description": "Whether the task queue's whole-queue rate limit is blocking dispatches. When true, adding more\nworkers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is\nuseful for auto-scaling systems to avoid unnecessary scale-up.\n\nThis reflects instantaneous state at the time of the query. If worker throughput is close to the rate\nlimit, this value may alternate between true and false across successive queries. Consumers should\napply their own smoothing or hysteresis to avoid oscillating scaling decisions.\n\nThis reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle\nindividual keys, but other keys can still benefit from additional workers, so per-key limiting alone\ndoes not set this flag." } }, "description": "TaskQueueStats contains statistics about task queue backlog and activity.\n\nFor workflow task queue type, this result is partial because tasks sent to sticky queues are not included. Read\ncomments above each metric to understand the impact of sticky queue exclusion on that metric accuracy." diff --git a/openapi/openapiv3.yaml b/openapi/openapiv3.yaml index 87f31b546..35ee6c250 100644 --- a/openapi/openapiv3.yaml +++ b/openapi/openapiv3.yaml @@ -17296,7 +17296,7 @@ components: rateLimitingActive: type: boolean description: |- - Whether the task queue's whole-queue rate limit is currently blocking dispatches. When true, adding more + Whether the task queue's whole-queue rate limit is blocking dispatches. When true, adding more workers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is useful for auto-scaling systems to avoid unnecessary scale-up. diff --git a/temporal/api/taskqueue/v1/message.proto b/temporal/api/taskqueue/v1/message.proto index 2fb523aa4..59467be56 100644 --- a/temporal/api/taskqueue/v1/message.proto +++ b/temporal/api/taskqueue/v1/message.proto @@ -144,7 +144,7 @@ message TaskQueueStats { // worker instance. float tasks_dispatch_rate = 4; - // Whether the task queue's whole-queue rate limit is currently blocking dispatches. When true, adding more + // Whether the task queue's whole-queue rate limit is blocking dispatches. When true, adding more // workers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is // useful for auto-scaling systems to avoid unnecessary scale-up. // From b171133fc384b47ddd2a39df293198be0837349b Mon Sep 17 00:00:00 2001 From: Kannan Rajah Date: Tue, 7 Jul 2026 11:43:32 -0700 Subject: [PATCH 7/8] Remove per-key rate limit detail from rate_limiting_active comment The flag represents whether rate limiting is blocking dispatches, without distinguishing which limiter is responsible. Co-Authored-By: Claude Opus 4.6 --- openapi/openapiv2.json | 2 +- openapi/openapiv3.yaml | 10 +++------- temporal/api/taskqueue/v1/message.proto | 10 +++------- 3 files changed, 7 insertions(+), 15 deletions(-) diff --git a/openapi/openapiv2.json b/openapi/openapiv2.json index f60426d40..ecac2c553 100644 --- a/openapi/openapiv2.json +++ b/openapi/openapiv2.json @@ -19572,7 +19572,7 @@ }, "rateLimitingActive": { "type": "boolean", - "description": "Whether the task queue's whole-queue rate limit is blocking dispatches. When true, adding more\nworkers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is\nuseful for auto-scaling systems to avoid unnecessary scale-up.\n\nThis reflects instantaneous state at the time of the query. If worker throughput is close to the rate\nlimit, this value may alternate between true and false across successive queries. Consumers should\napply their own smoothing or hysteresis to avoid oscillating scaling decisions.\n\nThis reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle\nindividual keys, but other keys can still benefit from additional workers, so per-key limiting alone\ndoes not set this flag." + "description": "Whether rate limiting is blocking dispatches. When true, adding more workers will not increase\nthroughput — the bottleneck is the rate limit, not worker count. This field is useful for auto-scaling\nsystems to avoid unnecessary scale-up.\n\nThis reflects instantaneous state at the time of the query. If worker throughput is close to the rate\nlimit, this value may alternate between true and false across successive queries. Consumers should\napply their own smoothing or hysteresis to avoid oscillating scaling decisions." } }, "description": "TaskQueueStats contains statistics about task queue backlog and activity.\n\nFor workflow task queue type, this result is partial because tasks sent to sticky queues are not included. Read\ncomments above each metric to understand the impact of sticky queue exclusion on that metric accuracy." diff --git a/openapi/openapiv3.yaml b/openapi/openapiv3.yaml index 35ee6c250..de6d18ebd 100644 --- a/openapi/openapiv3.yaml +++ b/openapi/openapiv3.yaml @@ -17296,17 +17296,13 @@ components: rateLimitingActive: type: boolean description: |- - Whether the task queue's whole-queue rate limit is blocking dispatches. When true, adding more - workers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is - useful for auto-scaling systems to avoid unnecessary scale-up. + Whether rate limiting is blocking dispatches. When true, adding more workers will not increase + throughput — the bottleneck is the rate limit, not worker count. This field is useful for auto-scaling + systems to avoid unnecessary scale-up. This reflects instantaneous state at the time of the query. If worker throughput is close to the rate limit, this value may alternate between true and false across successive queries. Consumers should apply their own smoothing or hysteresis to avoid oscillating scaling decisions. - - This reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle - individual keys, but other keys can still benefit from additional workers, so per-key limiting alone - does not set this flag. description: |- TaskQueueStats contains statistics about task queue backlog and activity. diff --git a/temporal/api/taskqueue/v1/message.proto b/temporal/api/taskqueue/v1/message.proto index 59467be56..10a8f195e 100644 --- a/temporal/api/taskqueue/v1/message.proto +++ b/temporal/api/taskqueue/v1/message.proto @@ -144,17 +144,13 @@ message TaskQueueStats { // worker instance. float tasks_dispatch_rate = 4; - // Whether the task queue's whole-queue rate limit is blocking dispatches. When true, adding more - // workers will not increase throughput — the bottleneck is the rate limit, not worker count. This field is - // useful for auto-scaling systems to avoid unnecessary scale-up. + // Whether rate limiting is blocking dispatches. When true, adding more workers will not increase + // throughput — the bottleneck is the rate limit, not worker count. This field is useful for auto-scaling + // systems to avoid unnecessary scale-up. // // This reflects instantaneous state at the time of the query. If worker throughput is close to the rate // limit, this value may alternate between true and false across successive queries. Consumers should // apply their own smoothing or hysteresis to avoid oscillating scaling decisions. - // - // This reflects only the whole-queue rate limit, not per-fairness-key limits. Per-key limits may throttle - // individual keys, but other keys can still benefit from additional workers, so per-key limiting alone - // does not set this flag. bool rate_limiting_active = 5; } From 3d3532dc23ab4498e522825d396044307ec0d708 Mon Sep 17 00:00:00 2001 From: Kannan Rajah Date: Tue, 7 Jul 2026 13:31:52 -0700 Subject: [PATCH 8/8] Update rate_limiting_active comment to reflect 30s observation window Co-Authored-By: Claude Opus 4.6 --- openapi/openapiv2.json | 2 +- openapi/openapiv3.yaml | 11 ++++------- temporal/api/taskqueue/v1/message.proto | 11 ++++------- 3 files changed, 9 insertions(+), 15 deletions(-) diff --git a/openapi/openapiv2.json b/openapi/openapiv2.json index ecac2c553..a91c3d84b 100644 --- a/openapi/openapiv2.json +++ b/openapi/openapiv2.json @@ -19572,7 +19572,7 @@ }, "rateLimitingActive": { "type": "boolean", - "description": "Whether rate limiting is blocking dispatches. When true, adding more workers will not increase\nthroughput — the bottleneck is the rate limit, not worker count. This field is useful for auto-scaling\nsystems to avoid unnecessary scale-up.\n\nThis reflects instantaneous state at the time of the query. If worker throughput is close to the rate\nlimit, this value may alternate between true and false across successive queries. Consumers should\napply their own smoothing or hysteresis to avoid oscillating scaling decisions." + "description": "Whether rate limiting blocked any dispatches within the recent observation window (approximately\n30 seconds). When true, adding more workers will not increase throughput — the bottleneck is the\nrate limit, not worker count. This field is useful for auto-scaling systems to avoid unnecessary\nscale-up." } }, "description": "TaskQueueStats contains statistics about task queue backlog and activity.\n\nFor workflow task queue type, this result is partial because tasks sent to sticky queues are not included. Read\ncomments above each metric to understand the impact of sticky queue exclusion on that metric accuracy." diff --git a/openapi/openapiv3.yaml b/openapi/openapiv3.yaml index de6d18ebd..d9694b90a 100644 --- a/openapi/openapiv3.yaml +++ b/openapi/openapiv3.yaml @@ -17296,13 +17296,10 @@ components: rateLimitingActive: type: boolean description: |- - Whether rate limiting is blocking dispatches. When true, adding more workers will not increase - throughput — the bottleneck is the rate limit, not worker count. This field is useful for auto-scaling - systems to avoid unnecessary scale-up. - - This reflects instantaneous state at the time of the query. If worker throughput is close to the rate - limit, this value may alternate between true and false across successive queries. Consumers should - apply their own smoothing or hysteresis to avoid oscillating scaling decisions. + Whether rate limiting blocked any dispatches within the recent observation window (approximately + 30 seconds). When true, adding more workers will not increase throughput — the bottleneck is the + rate limit, not worker count. This field is useful for auto-scaling systems to avoid unnecessary + scale-up. description: |- TaskQueueStats contains statistics about task queue backlog and activity. diff --git a/temporal/api/taskqueue/v1/message.proto b/temporal/api/taskqueue/v1/message.proto index 10a8f195e..ee1e823da 100644 --- a/temporal/api/taskqueue/v1/message.proto +++ b/temporal/api/taskqueue/v1/message.proto @@ -144,13 +144,10 @@ message TaskQueueStats { // worker instance. float tasks_dispatch_rate = 4; - // Whether rate limiting is blocking dispatches. When true, adding more workers will not increase - // throughput — the bottleneck is the rate limit, not worker count. This field is useful for auto-scaling - // systems to avoid unnecessary scale-up. - // - // This reflects instantaneous state at the time of the query. If worker throughput is close to the rate - // limit, this value may alternate between true and false across successive queries. Consumers should - // apply their own smoothing or hysteresis to avoid oscillating scaling decisions. + // Whether rate limiting blocked any dispatches within the recent observation window (approximately + // 30 seconds). When true, adding more workers will not increase throughput — the bottleneck is the + // rate limit, not worker count. This field is useful for auto-scaling systems to avoid unnecessary + // scale-up. bool rate_limiting_active = 5; }