Class JobVertexScaler
- java.lang.Object
-
- org.apache.flink.kubernetes.operator.autoscaler.JobVertexScaler
-
public class JobVertexScaler extends java.lang.Object
Component responsible for computing vertex parallelism based on the scaling metrics.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
INNEFFECTIVE_MESSAGE_FORMAT
-
Constructor Summary
Constructors Constructor Description JobVertexScaler(EventRecorder eventRecorder)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
computeScaleTargetParallelism(AbstractFlinkResource<?,?> resource, org.apache.flink.configuration.Configuration conf, org.apache.flink.runtime.jobgraph.JobVertexID vertex, java.util.Map<ScalingMetric,EvaluatedScalingMetric> evaluatedMetrics, java.util.SortedMap<java.time.Instant,ScalingSummary> history, io.fabric8.kubernetes.client.KubernetesClient client)
protected static int
scale(int parallelism, int numKeyGroups, double scaleFactor, int minParallelism, int maxParallelism)
protected void
setClock(java.time.Clock clock)
-
-
-
Field Detail
-
INNEFFECTIVE_MESSAGE_FORMAT
@VisibleForTesting public static final java.lang.String INNEFFECTIVE_MESSAGE_FORMAT
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
JobVertexScaler
public JobVertexScaler(EventRecorder eventRecorder)
-
-
Method Detail
-
computeScaleTargetParallelism
public int computeScaleTargetParallelism(AbstractFlinkResource<?,?> resource, org.apache.flink.configuration.Configuration conf, org.apache.flink.runtime.jobgraph.JobVertexID vertex, java.util.Map<ScalingMetric,EvaluatedScalingMetric> evaluatedMetrics, java.util.SortedMap<java.time.Instant,ScalingSummary> history, io.fabric8.kubernetes.client.KubernetesClient client)
-
scale
@VisibleForTesting protected static int scale(int parallelism, int numKeyGroups, double scaleFactor, int minParallelism, int maxParallelism)
-
setClock
@VisibleForTesting protected void setClock(java.time.Clock clock)
-
-