This is an automated email from the ASF dual-hosted git repository. gary pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/flink.git
The following commit(s) were added to refs/heads/master by this push: new c59f483 [FLINK-13136][docs] Fix documentation error about stopping job with restful api c59f483 is described below commit c59f4836fecc4069b2cffeae8dd81e50ea5d5e73 Author: yanghua <yanghua1...@gmail.com> AuthorDate: Thu Sep 12 21:59:08 2019 +0800 [FLINK-13136][docs] Fix documentation error about stopping job with restful api This closes #9013. --- docs/_includes/generated/rest_v1_dispatcher.html | 2 +- .../rest/messages/TerminationModeQueryParameter.java | 15 ++++++++------- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/docs/_includes/generated/rest_v1_dispatcher.html b/docs/_includes/generated/rest_v1_dispatcher.html index 11df6a5..57a542a 100644 --- a/docs/_includes/generated/rest_v1_dispatcher.html +++ b/docs/_includes/generated/rest_v1_dispatcher.html @@ -1060,7 +1060,7 @@ Using 'curl' you can upload a jar via 'curl -X POST -H "Expect:" -F "jarfile=@pa <tr> <td colspan="2"> <ul> -<li><code>mode</code> (optional): String value that specifies the termination mode. Supported values are: "cancel, stop".</li> +<li><code>mode</code> (optional): String value that specifies the termination mode. The only supported value is: "cancel".</li> </ul> </td> </tr> diff --git a/flink-runtime/src/main/java/org/apache/flink/runtime/rest/messages/TerminationModeQueryParameter.java b/flink-runtime/src/main/java/org/apache/flink/runtime/rest/messages/TerminationModeQueryParameter.java index 6fb5949..4cf4467 100644 --- a/flink-runtime/src/main/java/org/apache/flink/runtime/rest/messages/TerminationModeQueryParameter.java +++ b/flink-runtime/src/main/java/org/apache/flink/runtime/rest/messages/TerminationModeQueryParameter.java @@ -18,11 +18,8 @@ package org.apache.flink.runtime.rest.messages; -import org.apache.flink.util.StringUtils; - /** - * Termination mode. - * @deprecated Only kept to detect legacy usages of the cancel/stop command. Please use the "stop" command instead. + * Termination mode query parameter. */ public class TerminationModeQueryParameter extends MessageQueryParameter<TerminationModeQueryParameter.TerminationMode> { @@ -44,15 +41,19 @@ public class TerminationModeQueryParameter extends MessageQueryParameter<Termina @Override public String getDescription() { - return "String value that specifies the termination mode. Supported values are: " + - StringUtils.toQuotedListString(TerminationMode.values()) + '.'; + return "String value that specifies the termination mode. The only supported value is: \"" + + TerminationMode.CANCEL.name().toLowerCase() + "\"."; } /** - * @deprecated Please use the "stop" command instead. + * Termination mode. */ public enum TerminationMode { CANCEL, + + /** + * @deprecated Please use the "stop" command instead. + */ STOP } }