zentol commented on a change in pull request #14399:
URL: https://github.com/apache/flink/pull/14399#discussion_r551277806



##########
File path: flink-scala-shell/start-script/start-scala-shell.sh
##########
@@ -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") ]]
+if [[ $MODE = "yarn" ]]
 then
-    LOG4J_CONFIG=log4j.properties
-    LOGBACK_CONFIG=logback.xml
-elif [[ $1 = "yarn" ]]
-then
-    LOG4J_CONFIG=log4j-session.properties
+       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

Review comment:
       ```suggestion
       LOG4J_CONFIG=log4j.properties
   ```




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to