Skip to Content
Core InfraReplicas OptimizationReplica Threshold Optimization (beta)

Replica Threshold Optimization (beta)
Available in v1.30.18+

Replica Threshold Optimization automatically sets CPU scaling thresholds by estimating SLA compliance from historical latency data — reducing unnecessary scaling while protecting reliability.

Feature Enablement

To use this feature, ScaleOps API observability must be enabled.

Replica threshold optimization is not enabled in built-in policies by default. Customers can turn it on globally, which replaces every regular built-in policy with a variant that has threshold optimization enabled.

You can enable threshold optimization via the UI or by setting the following Helm value:

global: thresholdOptimization: enabled: true

This value activates API observability alongside threshold optimization when it is not already running.

Policy Configuration

Policy settings for threshold optimization are available under Replicas Optimization policies, in the Threshold group.

Custom Target Latency
Available in v1.32.5+

ScaleOps applies a default p99 latency target when optimizing CPU thresholds. Custom target latency lets teams override this at the policy level — defining their own latency target to control how aggressively the threshold is optimized.

A stricter (lower) target keeps the threshold closer to the original value, prioritizing latency protection. A looser (higher) target allows more aggressive threshold optimization, prioritizing cost savings.

Custom target latency can be configured via replica optimization policies management in the ScaleOps UI.

When no custom target is set, ScaleOps applies its default p99 latency target based on observed workload behavior.

Healing

Threshold optimization includes a dedicated healing mechanism that detects SLA compliance drift or elevated error rates and triggers a staged revert.

Revert Logic

When a drift is detected, ScaleOps gradually reverts the CPU threshold — falling back to the last applied threshold value if one exists, or to the original pre-optimization value if no prior applied value is available. If the issue persists, ScaleOps reverts all the way to the original value.

⚠️

Unlike CPU and OOM auto-healing, replica threshold healing only reverts the threshold to its previous or original value. It does not generate a new, lower recommendation. The goal is stability — not further optimization — during a degradation event.

Constraints

  • CPU thresholds only — the feature currently optimizes CPU-based HPA/KEDA triggers. Other metric types are not supported.
  • API observability required — ScaleOps must have API observability enabled to collect the latency data needed for threshold calculation.
  • Workloads with incoming traffic only — workloads that do not receive external requests will not be detected or optimized, as there is no latency signal to correlate against.