Class AutoscalerFlinkMetrics


  • public class AutoscalerFlinkMetrics
    extends java.lang.Object
    Autoscaler metrics for observability.
    • Field Detail

      • CURRENT

        @VisibleForTesting
        public static final java.lang.String CURRENT
        See Also:
        Constant Field Values
      • AVERAGE

        @VisibleForTesting
        public static final java.lang.String AVERAGE
        See Also:
        Constant Field Values
      • JOB_VERTEX_ID

        @VisibleForTesting
        public static final java.lang.String JOB_VERTEX_ID
        See Also:
        Constant Field Values
    • Constructor Detail

      • AutoscalerFlinkMetrics

        public AutoscalerFlinkMetrics​(org.apache.flink.metrics.MetricGroup metricGroup)
    • Method Detail

      • incrementScaling

        public void incrementScaling()
      • incrementError

        public void incrementError()
      • incrementBalanced

        public void incrementBalanced()
      • registerScalingMetrics

        public void registerScalingMetrics​(java.util.List<org.apache.flink.runtime.jobgraph.JobVertexID> jobVertices,
                                           java.util.function.Supplier<EvaluatedMetrics> metricsSupplier)
      • initRecommendedParallelism

        public static void initRecommendedParallelism​(java.util.Map<org.apache.flink.runtime.jobgraph.JobVertexID,​java.util.Map<ScalingMetric,​EvaluatedScalingMetric>> evaluatedMetrics)
      • resetRecommendedParallelism

        @VisibleForTesting
        public static void resetRecommendedParallelism​(java.util.Map<org.apache.flink.runtime.jobgraph.JobVertexID,​java.util.Map<ScalingMetric,​EvaluatedScalingMetric>> evaluatedMetrics)
      • getNumScalingsCount

        @VisibleForTesting
        public long getNumScalingsCount()
      • getNumErrorsCount

        @VisibleForTesting
        public long getNumErrorsCount()
      • getNumBalancedCount

        @VisibleForTesting
        public long getNumBalancedCount()
      • getMetricGroup

        @VisibleForTesting
        public org.apache.flink.metrics.MetricGroup getMetricGroup()