mxm commented on code in PR #699:
URL:
https://github.com/apache/flink-kubernetes-operator/pull/699#discussion_r1379821385
##########
flink-autoscaler/src/main/java/org/apache/flink/autoscaler/ScalingMetricCollector.java:
##########
@@ -343,8 +346,19 @@ private double computeLagGrowthRate(
return (currentLag - lastLag) / timeDiff;
}
+ private Map<JobVertexID, Map<String, FlinkMetric>>
queryFilteredMetricNames(
+ Context ctx, JobTopology topology, boolean isStabilizing) {
+ try {
+ return queryFilteredMetricNames(ctx, topology);
+ } catch (MetricNotFoundException e) {
+ if (isStabilizing) {
+ throw new RecoverableException(e);
+ }
+ throw e;
+ }
+ }
+
/** Query the available metric names for each job vertex. */
- @SneakyThrows
protected Map<JobVertexID, Map<String, FlinkMetric>>
queryFilteredMetricNames(
Context ctx, JobTopology topology) {
Review Comment:
I did not inline because this method is overridden in tests, e.g.
`TestingScalingCollector`. Inlining the newly-added method into the protected
method would change the behavior. I wanted to make sure that the newly added
method is never overridden.
--
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]