-
Notifications
You must be signed in to change notification settings - Fork 40.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve documentation for exit code generation #5038
Comments
It's required to call the
You're not doing anything with the application's exit code, i.e. you haven't passed it into a call to Take a look at System.exit(SpringApplication
.exit(SpringApplication.run(SampleBatchApplication.class, args))); |
OK my bad I should have posted it to SW. But isn't it good to have it documented as well. |
Closing in favour of PR #9740 |
I was using the exit code generator feature and as per the document
Does this bean gets called whenever a proper shut down happen, or it require a call to SpringApplication.exit static method?
For me first option is not happening on a spring boot console application i.e. no web dependency. But when I call the SpringApplication.exit static method ExitCodeGenerator.getExitCode is called but still returns exit code 0 and also it forces the tests to fail with a message that
example can be found here boot-exitcode
The text was updated successfully, but these errors were encountered: