tillrohrmann commented on a change in pull request #7356:
[FLINK-10868][flink-yarn] Enforce maximum TMs failure rate in ResourceManagers
URL: https://github.com/apache/flink/pull/7356#discussion_r252364001
##########
File path:
flink-runtime/src/main/java/org/apache/flink/runtime/resourcemanager/ResourceManager.java
##########
@@ -145,6 +148,15 @@
/** All registered listeners for status updates of the ResourceManager.
*/
private ConcurrentMap<String, InfoMessageListenerRpcGateway>
infoMessageListeners;
+ protected final Time failureInterval;
+
+ protected final int maximumFailureTaskExecutorPerInternal;
+
+ private boolean checkFailureRate;
+
+ private final ArrayDeque<Long> taskExecutorFailureTimestamps;
Review comment:
I think we should encapsulate the metering logic behind some interface.
Ideally I would like to use exponentially-weighted moving average to
approximate the failure rate. This would have the benefit that we would not
have to store every timestamp here. However, with an interface we could also
have different implementations (e.g. the exact one you have implemented here).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services