wangyang0918 commented on a change in pull request #12240:
URL: https://github.com/apache/flink/pull/12240#discussion_r466107541



##########
File path: 
flink-kubernetes/src/main/java/org/apache/flink/kubernetes/utils/KubernetesUtils.java
##########
@@ -213,10 +211,11 @@ private static String getLogging(String logFile, String 
confDir, boolean hasLogb
                if (hasLogback || hasLog4j) {
                        logging.append("-Dlog.file=").append(logFile);
                        if (hasLogback) {
-                               logging.append(" 
-Dlogback.configurationFile=file:").append(confDir).append("/logback.xml");
+                               logging.append(" 
-Dlogback.configurationFile=file:").append(confDir).append("/").append(CONFIG_FILE_LOGBACK_NAME);
                        }
                        if (hasLog4j) {
-                               logging.append(" 
-Dlog4j.configurationFile=file:").append(confDir).append("/log4j.properties");
+                               logging.append(" 
-Dlog4j.configuration=file:").append(confDir).append("/").append(CONFIG_FILE_LOG4J_NAME)
+                                       .append(" 
-Dlog4j.configurationFile=file:").append(confDir).append("/").append(CONFIG_FILE_LOG4J_NAME);
                        }

Review comment:
       For standalone and Yarn deployment, we could support both log4j1 and 
log4j2. We should do this for K8s deployment. `log4j.configuration` is for 
log4j1 and `log4j.configurationFile` is for log4j2.




----------------------------------------------------------------
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:
[email protected]


Reply via email to