This is an automated email from the ASF dual-hosted git repository. zjffdu pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/zeppelin.git
The following commit(s) were added to refs/heads/master by this push: new 7a07454 [ZEPPELIN-4417]. Logging Interpreter launch command in log4j 7a07454 is described below commit 7a0745430ebdd69b993b60cfdfc69790ae30dd18 Author: Jeff Zhang <zjf...@apache.org> AuthorDate: Mon Nov 4 12:48:52 2019 +0800 [ZEPPELIN-4417]. Logging Interpreter launch command in log4j ### What is this PR for? This PR is to logging interpreter launch command in log4j for diagnose purpose. ### What type of PR is it? [Improvement] ### Todos * [ ] - Task ### What is the Jira issue? * https://issues.apache.org/jira/browse/ZEPPELIN-4417 ### How should this be tested? * Manually tested, launching spark interpreter, and see the spark submit command in log4j Here's the sample log: ``` INFO [2019-11-04 21:59:46,077] ({SchedulerFactory2} ProcessLauncher.java[transition]:86) - Process state is transitioned to LAUNCHED INFO [2019-11-04 21:59:46,077] ({SchedulerFactory2} ProcessLauncher.java[launch]:73) - Process is launched: [/Users/jzhang/github/zeppelin/bin/interpreter.sh, -d, /Users/jzhang/github/zeppelin/interpreter/python, -c, 0.0.0.0, -p, 49739, -r, :, -i, python-shared_process, -l, /Users/jzhang/github/zeppelin/local-repo/python, -g, python] INFO [2019-11-04 21:59:46,126] ({Exec Stream Pumper} ProcessLauncher.java[processLine]:160) - Interpreter launch command: /Library/Java/JavaVirtualMachines/jdk1.8.0_211.jdk/Contents/Home/bin/java -Dfile.encoding=UTF-8 -Dlog4j.configuration=file:///Users/jzhang/github/zeppelin/conf/log4j.properties -Dzeppelin.log.file='/Users/jzhang/github/zeppelin/logs/zeppelin-interpreter-python-shared_process-jzhang-JeffdeMacBook-Pro.local.log' -Xms1024m -Xmx1024m -XX:MaxPermSize=512m -cp ":/Users [...] INFO [2019-11-04 21:59:46,770] ({pool-5-thread-1} ProcessLauncher.java[transition]:86) - Process state is transitioned to RUNNING ``` ### Questions: * Does the licenses files need update? No * Is there breaking changes for older versions? No * Does this needs documentation? No Author: Jeff Zhang <zjf...@apache.org> Closes #3509 from zjffdu/ZEPPELIN-4417 and squashes the following commits: c257e19ec [Jeff Zhang] [ZEPPELIN-4417]. Logging interpreter launch command in log4j --- .../java/org/apache/zeppelin/interpreter/util/ProcessLauncher.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/util/ProcessLauncher.java b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/util/ProcessLauncher.java index 14558a1..5e6c8c9 100644 --- a/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/util/ProcessLauncher.java +++ b/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/util/ProcessLauncher.java @@ -155,7 +155,12 @@ public abstract class ProcessLauncher implements ExecuteResultHandler { @Override protected void processLine(String s, int i) { - LOGGER.debug("Process Output: " + s); + // print Interpreter launch command for diagnose purpose + if (s.startsWith("Interpreter launch command")) { + LOGGER.info(s); + } else { + LOGGER.debug("Process Output: " + s); + } if (catchLaunchOutput) { launchOutput.append(s + "\n"); }