afedulov commented on code in PR #759: URL: https://github.com/apache/flink-kubernetes-operator/pull/759#discussion_r1467622312
########## flink-autoscaler/src/main/java/org/apache/flink/autoscaler/JobAutoScalerImpl.java: ########## @@ -160,14 +160,23 @@ private void runScalingLogic(Context ctx, AutoscalerFlinkMetrics autoscalerMetri var collectedMetrics = metricsCollector.updateMetrics(ctx, stateStore); var jobTopology = collectedMetrics.getJobTopology(); + var now = clock.instant(); Review Comment: @1996fanrui using `jobUpdateTs` looks like a good idea to me and it also seems to be safe - the `runRescaleLogic` is only executed when the job is in `RUNNING` state, hence the last timestamp fetched in the `ScalingMetricCollector.getJobUpdateTs()` for a rescaled job should be correct one. We could add an extra filter for `RUNNING` on top of `JobStatus.timestamps` to make the implementation more robust against future refactorings. -- 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: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org