Skip to content
Snippets Groups Projects
  • Marcelo Vanzin's avatar
    36c5892b
    [SPARK-13670][LAUNCHER] Propagate error from launcher to shell. · 36c5892b
    Marcelo Vanzin authored
    bash doesn't really propagate errors from subshells when using redirection
    the way spark-class does; so, instead, this change captures the exit code
    of the launcher process in the command array, and checks it before executing
    the actual command.
    
    Tested by injecting an error in Main.java (the launcher entry point) and
    verifying the shell gets the right exit code from spark-class.
    
    Author: Marcelo Vanzin <vanzin@cloudera.com>
    
    Closes #12910 from vanzin/SPARK-13670.
    36c5892b
    History
    [SPARK-13670][LAUNCHER] Propagate error from launcher to shell.
    Marcelo Vanzin authored
    bash doesn't really propagate errors from subshells when using redirection
    the way spark-class does; so, instead, this change captures the exit code
    of the launcher process in the command array, and checks it before executing
    the actual command.
    
    Tested by injecting an error in Main.java (the launcher entry point) and
    verifying the shell gets the right exit code from spark-class.
    
    Author: Marcelo Vanzin <vanzin@cloudera.com>
    
    Closes #12910 from vanzin/SPARK-13670.