Uploaded image for project: 'Flink'
  1. Flink
  2. FLINK-10743

Use 0 processExitCode for ApplicationStatus.CANCELED

    XMLWordPrintableJSON

Details

    Description

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

      Attachments

        Issue Links

          Activity

            People

              uce Ufuk Celebi
              uce Ufuk Celebi
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: