You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2019/06/03 09:12:05 UTC

[GitHub] [flink] eaglewatcherwb commented on a change in pull request #8573: [FLINK-12670][runtime] Implement FailureRateRestartBackoffTimeStrategy

eaglewatcherwb commented on a change in pull request #8573: [FLINK-12670][runtime] Implement FailureRateRestartBackoffTimeStrategy
URL: https://github.com/apache/flink/pull/8573#discussion_r289752903
 
 

 ##########
 File path: flink-core/src/main/java/org/apache/flink/configuration/ConfigConstants.java
 ##########
 @@ -117,6 +117,30 @@
 	@PublicEvolving
 	public static final String EXECUTION_RETRY_DELAY_KEY = "execution-retries.delay";
 
+	/**
+	 * Maximum number of failures in given time interval {@link #RESTART_BACKOFF_TIME_STRATEGY_FAILURE_RATE_FAILURE_RATE_INTERVAL}
+	 * before failing a job in FailureRateRestartBackoffTimeStrategy.
+	 */
+	@PublicEvolving
+	public static final ConfigOption<Integer> RESTART_BACKOFF_TIME_STRATEGY_FAILURE_RATE_MAX_FAILURES_PER_INTERVAL =
+		key("restart-backoff-time-strategy.failure-rate.max-failures-per-interval").defaultValue(1);
+
+	/**
+	 * Time interval in which greater amount of failures than {@link #RESTART_BACKOFF_TIME_STRATEGY_FAILURE_RATE_MAX_FAILURES_PER_INTERVAL}
+	 * causes job fail in FailureRateRestartBackoffTimeStrategy. It can be specified using Scala's FiniteDuration notation: "1 min", "20 s"
+	 */
+	@PublicEvolving
+	public static final ConfigOption<String> RESTART_BACKOFF_TIME_STRATEGY_FAILURE_RATE_FAILURE_RATE_INTERVAL =
+		key("restart-backoff-time-strategy.failure-rate.failure-rate-interval").defaultValue("1 min");
+
+	/**
+	 * Backoff time between two consecutive restart attempts in FailureRateRestartBackoffTimeStrategy.
+	 * It can be specified using Scala's FiniteDuration notation: "1 min", "20 s".
+	 */
+	@PublicEvolving
+	public static final ConfigOption<String> RESTART_BACKOFF_TIME_STRATEGY_RESTART_BACKOFF_TIME =
 
 Review comment:
   I think RestartBackoffTimeStrategyOptions is better, since it looks more clear and is consistent with current configuration structure. It may be a little messy if we put options into corresponding strategies since we may support more strategies in the future.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services