[ 
https://issues.apache.org/jira/browse/FLINK-10743?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16714916#comment-16714916
 ] 

ASF GitHub Bot commented on FLINK-10743:
----------------------------------------

tillrohrmann commented on a change in pull request #7004: [FLINK-10743] 
[runtime] Use 0 processExitCode for ApplicationStatus.CANCELED
URL: https://github.com/apache/flink/pull/7004#discussion_r240246265
 
 

 ##########
 File path: 
flink-runtime/src/test/java/org/apache/flink/runtime/clusterframework/ApplicationStatusTest.java
 ##########
 @@ -0,0 +1,70 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.flink.runtime.clusterframework;
+
+import static org.hamcrest.Matchers.contains;
+import static org.hamcrest.Matchers.equalTo;
+import static org.hamcrest.Matchers.is;
+import static org.hamcrest.Matchers.not;
+import static org.junit.Assert.assertThat;
+
+import java.util.Arrays;
+import java.util.stream.Collectors;
+import java.util.stream.StreamSupport;
+import org.junit.Test;
+
+public class ApplicationStatusTest {
 
 Review comment:
   Should extend `TestLogger`

----------------------------------------------------------------
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]


> Use 0 processExitCode for ApplicationStatus.CANCELED
> ----------------------------------------------------
>
>                 Key: FLINK-10743
>                 URL: https://issues.apache.org/jira/browse/FLINK-10743
>             Project: Flink
>          Issue Type: Bug
>          Components: Cluster Management, Kubernetes, Mesos, YARN
>    Affects Versions: 1.6.3, 1.7.0
>            Reporter: Ufuk Celebi
>            Assignee: Ufuk Celebi
>            Priority: Minor
>              Labels: pull-request-available
>             Fix For: 1.8.0
>
>
> {{org.apache.flink.runtime.clusterframework.ApplicationStatus}} is used to 
> map {{org.apache.flink.runtime.jobgraph.JobStatus}} to a process exit code.
> We currently map {{ApplicationStatus.CANCELED}} to a non-zero exit code 
> ({{1444}}). Since cancellation is a user-triggered operation I would consider 
> this to be a successful exit and map it to exit code {{0}}.
> Our current behavior results in applications running via the 
> {{StandaloneJobClusterEntryPoint}} and Kubernetes pods as documented in 
> [flink-container|https://github.com/apache/flink/tree/master/flink-container/kubernetes]
>  to be immediately restarted when cancelled. This only leaves the option of 
> killing the respective job cluster master container.
> The {{ApplicationStatus}} is also used in the YARN and Mesos clients, but I'm 
> not familiar with that part of the code base and can't asses how changing the 
> exit code would affect these clients. A quick usage scan for 
> {{ApplicationStatus.CANCELED}} did not surface any problematic usages though.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to