未验证 提交 507e7c57 编写于 作者: P paul8263 提交者: GitHub

[FLINK-17827][scala-shell] Setup default logging settings

上级 201803c6
......@@ -82,15 +82,15 @@ fi
MODE=$1
LOG=$FLINK_LOG_DIR/flink-$FLINK_IDENT_STRING-scala-shell-$MODE-$HOSTNAME.log
if [[ ($MODE = "local") || ($MODE = "remote") ]]
then
LOG4J_CONFIG=log4j.properties
LOGBACK_CONFIG=logback.xml
elif [[ $1 = "yarn" ]]
if [[ $MODE = "yarn" ]]
then
LOG4J_CONFIG=log4j-session.properties
LOGBACK_CONFIG=logback-session.xml
FLINK_CLASSPATH=$FLINK_CLASSPATH:$HADOOP_CLASSPATH:$HADOOP_CONF_DIR:$YARN_CONF_DIR
else
# Set the default log config when MODE is something other than yarn. eg: local, remote or other invalid mode.
LOG4J_CONFIG=log4j.properties
LOGBACK_CONFIG=logback.xml
fi
log_setting=("-Dlog.file=$LOG" "-Dlog4j.configuration=file:$FLINK_CONF_DIR/$LOG4J_CONFIG" "-Dlog4j.configurationFile=file:$FLINK_CONF_DIR/$LOG4J_CONFIG" "-Dlogback.configurationFile=file:$FLINK_CONF_DIR/$LOGBACK_CONFIG")
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册