Fly-Style commented on code in PR #18976:
URL: https://github.com/apache/druid/pull/18976#discussion_r2769597249
##########
indexing-service/src/main/java/org/apache/druid/indexing/seekablestream/supervisor/autoscaler/CostBasedAutoScaler.java:
##########
@@ -314,32 +322,46 @@ static int[] computeValidTaskCounts(
/**
* Computes extra allowed increase in partitions-per-task in scenarios when
the average per-partition lag
- * is above the configured threshold. By default, it is {@code
EXTRA_SCALING_ACTIVATION_LAG_THRESHOLD}.
- * Generally, one of the autoscaler priorities is to keep the lag as close
to zero as possible.
+ * is above the configured threshold.
+ * <p>
+ * This uses a logarithmic formula for consistent absolute growth:
+ * {@code deltaTasks = K * ln(lagSeverity)}
+ * where {@code K = (partitionCount / 6.4) / sqrt(currentTaskCount)}
+ * <p>
+ * This ensures that small taskCount's get a massive relative boost,
+ * while large taskCount's receive more measured, stable increases.
*/
- static int computeExtraMaxPartitionsPerTaskIncrease(
+ static int computeExtraPPTIncrease(
Review Comment:
Would leave it for some follow-up PR, actually want to start testing that
stuff soon.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]