Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Duplicate
-
4.2.0
-
None
-
None
-
All
Description
Change were recently made in OOZIE-2244 to mask passwords in logs when printing arguments. These changes cause failures in workflows that use basic EL functions that result in null values.
For instance if someone is using the EL replaceAll function and it returns an empty string as a result (which is considered null) the following code fails (https://github.com/apache/oozie/commit/3276633f3002ad7e9096c4ee5b6c329f5a708248):
if (arg.toLowerCase().contains("password"))
This was working previously because at some point the null does get converted to an empty string, but it's after the point in which the args are printed.
An example of an EL function causing this failure, where property foo was equal to "ALL":
<arg>${replaceAll(foo, "^[aA][lL][lL]$", "")}</arg>
ST:
.... null Failing Oozie Launcher, Main class [org.apache.oozie.action.hadoop.JavaMain], exception invoking main(), null java.lang.NullPointerException at org.apache.oozie.action.hadoop.LauncherMapper.printArgs(LauncherMapper.java:627) at org.apache.oozie.action.hadoop.LauncherMapper.map(LauncherMapper.java:212) at org.apache.hadoop.mapred.MapRunner.run(MapRunner.java:54) at org.apache.hadoop.mapred.MapTask.runOldMapper(MapTask.java:453) at org.apache.hadoop.mapred.MapTask.run(MapTask.java:343) at org.apache.hadoop.mapred.YarnChild$2.run(YarnChild.java:164) at java.security.AccessController.doPrivileged(Native Method) at javax.security.auth.Subject.doAs(Subject.java:422) at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1698) at org.apache.hadoop.mapred.YarnChild.main(YarnChild.java:158)
Attachments
Issue Links
- duplicates
-
OOZIE-2748 NPE in LauncherMapper.printArgs()
- Closed
- is broken by
-
OOZIE-2244 Oozie should mask passwords in the logs when logging command arguments
- Closed