This is an automated email from the ASF dual-hosted git repository.
kfaraz pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/druid.git
The following commit(s) were added to refs/heads/master by this push:
new be1863f0bfe feat: Always allow scaling during task rollover in
costBased auto-scaler (#19750)
be1863f0bfe is described below
commit be1863f0bfeaee15d9479a8fab897c0a7b294c33
Author: Kashif Faraz <[email protected]>
AuthorDate: Sat Jul 25 19:11:45 2026 +0530
feat: Always allow scaling during task rollover in costBased auto-scaler
(#19750)
Sometimes scaling decisions can get rejected if there are some tasks
pending completion.
This becomes problematic when there are task failures as the failure to
scale up compounds
the issue and the lag builds up rapidly.
Fix:
Always allow scaling during task rollover and not only when
`scaleDownDuringTaskRolloverOnly`
is `true`. Scaling during task rollover is not rejected even if there are
tasks pending completion.
---
.../supervisor/autoscaler/CostBasedAutoScaler.java | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git
a/indexing-service/src/main/java/org/apache/druid/indexing/seekablestream/supervisor/autoscaler/CostBasedAutoScaler.java
b/indexing-service/src/main/java/org/apache/druid/indexing/seekablestream/supervisor/autoscaler/CostBasedAutoScaler.java
index abada2f9b74..4a534b1a05d 100644
---
a/indexing-service/src/main/java/org/apache/druid/indexing/seekablestream/supervisor/autoscaler/CostBasedAutoScaler.java
+++
b/indexing-service/src/main/java/org/apache/druid/indexing/seekablestream/supervisor/autoscaler/CostBasedAutoScaler.java
@@ -177,11 +177,10 @@ public class CostBasedAutoScaler implements
SupervisorTaskAutoScaler
@Override
public int computeTaskCountForRollover()
{
- if (config.isScaleDownOnTaskRolloverOnly()) {
- return computeOptimalTaskCount(lastKnownMetrics);
- } else {
- return CANNOT_COMPUTE;
- }
+ // Always allow scaling on task rollover.
+ // If a scaling has happened recently, the caller may not invoke this
method
+ // at all or simply reject the task count returned.
+ return computeOptimalTaskCount(lastKnownMetrics);
}
public int computeTaskCountForScaleAction()
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]