zentol commented on a change in pull request #17735:
URL: https://github.com/apache/flink/pull/17735#discussion_r754337057
##########
File path:
flink-runtime/src/main/java/org/apache/flink/runtime/scheduler/adaptive/AdaptiveScheduler.java
##########
@@ -265,7 +268,8 @@ public AdaptiveScheduler(
this.executionGraphFactory = executionGraphFactory;
- registerMetrics();
+ SchedulerBase.registerJobMetrics(
+ jobManagerJobMetricGroup, jobStatusStore, () -> (long)
numRestarts);
Review comment:
> Does numRestarts need to be volatile?
Technically yes, but we generally don't do it. It would be too expensive on
the hot code paths (aka, we can't be consistent about it anyway), and we
haven't had issues so far 🤷
> Or is there some synchronization in the metrics system that I'm missing?
There is none.
--
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]