Uploaded image for project: 'BatchEE'
  1. BatchEE
  2. BATCHEE-123

Exit status on Exception

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Not A Problem
    • 0.4-incubating
    • None
    • CLI
    • None

    Description

      If a batch job throws an arbitrary exception, i think the CLI batchrunner show return a non-zero exit status per default.

      I know, throwing an custom RuntimeException annotated with org.apache.batchee.cli.command.api.Exit will do the trick. But wrapping every reader, processor, writer and batchlet in a big try-catch block sounds a bit ugly.

      I would suggest wrapping the whole org.apache.batchee.cli.bootstrap.Bootstrap#main in a try-catch block, catching Exception, printing the stacktrace and exiting with some default non-zero exit status.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            Unassigned Unassigned
            elexx Alexander Falb
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment