spark-instrumented-optimizer/yarn
peng.zhang 14f8c34040 [YARN] SPARK-2668: Add variable of yarn log directory for reference from the log4j configuration
Assign value of yarn container log directory to java opts "spark.yarn.app.container.log.dir", So user defined log4j.properties can reference this value and write log to YARN container's log directory.
Otherwise, user defined file appender will only write to container's CWD, and log files in CWD will not be displayed on YARN UI,and either cannot be aggregated to HDFS log directory after job finished.

User defined log4j.properties reference example:
log4j.appender.rolling_file.File = ${spark.yarn.app.container.log.dir}/spark.log

Author: peng.zhang <peng.zhang@xiaomi.com>

Closes #1573 from renozhang/yarn-log-dir and squashes the following commits:

16c5cb8 [peng.zhang] Update doc
f2b5e2a [peng.zhang] Change variable's name, and update running-on-yarn.md
503ea2d [peng.zhang] Support log4j log to yarn container dir
2014-09-23 08:45:56 -05:00
..
alpha [SPARK-3456] YarnAllocator on alpha can lose container requests to RM 2014-09-12 20:31:11 -05:00
common/src [YARN] SPARK-2668: Add variable of yarn log directory for reference from the log4j configuration 2014-09-23 08:45:56 -05:00
stable [SPARK-3456] YarnAllocator on alpha can lose container requests to RM 2014-09-12 20:31:11 -05:00
pom.xml [SPARK-3452] Maven build should skip publishing artifacts people shouldn... 2014-09-14 21:17:29 -07:00
README.md fix docs for yarn 2014-01-03 14:14:35 +08:00

YARN DIRECTORY LAYOUT

Hadoop Yarn related codes are organized in separate directories to minimize duplicated code.

  • common : Common codes that do not depending on specific version of Hadoop.

  • alpha / stable : Codes that involve specific version of Hadoop YARN API.

alpha represents 0.23 and 2.0.x stable represents 2.2 and later, until the API changes again.

alpha / stable will build together with common dir into a single jar