OOZIE-3716 [sharelib-oozie] Fix complete message order #88
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of PR
When you execute oozie java action, there is no message like below if LauncherSecurityManager throws an exceptions.
However, if system exit code from LauncherSecurityManager is zero, it is possible to consider main() method finished successfully.
Therefore, there is no problem with printing "<<< Invocation of Main class completed <<<" message in such cases.
Oozie 4.x version prints the message in finally block but Oozie 5.x version does not(There is Transition from LauncherMapper to LauncherAM class in oozie 5.x version.)
oozie/sharelib/oozie/src/main/java/org/apache/oozie/action/hadoop/LauncherMapper.java
Lines 232 to 272 in 3d08432
This issue may be negligible but can cause a problem in hue editor.
hue uses regular expression to distinguish whether oozie java action is successfull or not.
https://github.com/cloudera/hue/blob/c0443438e9a29b9fbf22566022aeef27fc4c606b/desktop/libs/notebook/src/notebook/connectors/oozie_batch.py#L54
The regular expression does not match if there is no "<<< Invocation of Main class completed <<<" message so that hue considers oozie java action is not completed even though main method of oozie java action is successful.
related issue