You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Robert Metzger (Jira)" <ji...@apache.org> on 2021/01/18 19:01:00 UTC

[jira] [Closed] (FLINK-15156) Warn user if System.exit() is called in user code

     [ https://issues.apache.org/jira/browse/FLINK-15156?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Robert Metzger closed FLINK-15156.
----------------------------------
    Release Note: 
A new configuration value `cluster.intercept-user-system-exit` allows to log a warning, or throw an exception if user code calls "System.exit()".

This feature is not covering all locations in Flink where user code is executed. It just adds the infrastructure for such an interception.
      Resolution: Fixed

Resolved in https://github.com/apache/flink/commit/9098cfe4a067a4fe12122e8561eb5869b564ebc0.

Thanks a lot for working on this [~hwanju]!
I'm sorry that the review was so involved. Let's hope the next one is smoother! 

> Warn user if System.exit() is called in user code
> -------------------------------------------------
>
>                 Key: FLINK-15156
>                 URL: https://issues.apache.org/jira/browse/FLINK-15156
>             Project: Flink
>          Issue Type: Improvement
>          Components: Runtime / Coordination
>            Reporter: Robert Metzger
>            Assignee: Hwanju Kim
>            Priority: Minor
>              Labels: pull-request-available, starter
>             Fix For: 1.13.0
>
>
> It would make debugging Flink errors easier if we would intercept and log calls to System.exit() through the SecurityManager.
> A user recently had an error where the JobManager was shutting down because of a System.exit() in the user code: https://lists.apache.org/thread.html/b28dabcf3068d489f38399c456c80d48569fcdf74b15f8bb95d532d0%40%3Cuser.flink.apache.org%3E
> If I remember correctly, we had such issues before.
> I put this ticket into the "Runtime / Coordination" component, as it is mostly about improving the usability / debuggability in that area.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)