mxsm commented on code in PR #5709:
URL: https://github.com/apache/rocketmq/pull/5709#discussion_r1051011158


##########
namesrv/src/main/java/org/apache/rocketmq/namesrv/NamesrvStartup.java:
##########
@@ -112,25 +113,26 @@ public static void parseCommandlineAndConfigFile(String[] 
args) throws Exception
             }
         }
 
+        
MixAll.properties2Object(ServerUtil.commandLine2Properties(commandLine), 
namesrvConfig);
         if (commandLine.hasOption('p')) {
-            MixAll.printObjectProperties(null, namesrvConfig);
-            MixAll.printObjectProperties(null, nettyServerConfig);
-            MixAll.printObjectProperties(null, nettyClientConfig);
-            MixAll.printObjectProperties(null, controllerConfig);
+            MixAll.printObjectProperties(LOGGER_CONSOLE, namesrvConfig);
+            MixAll.printObjectProperties(LOGGER_CONSOLE, nettyServerConfig);
+            MixAll.printObjectProperties(LOGGER_CONSOLE, nettyClientConfig);
+            if (namesrvConfig.isEnableControllerInNamesrv()) {
+                MixAll.printObjectProperties(LOGGER_CONSOLE, controllerConfig);
+            }
             System.exit(0);
         }
 
-        
MixAll.properties2Object(ServerUtil.commandLine2Properties(commandLine), 
namesrvConfig);
-
         if (null == namesrvConfig.getRocketmqHome()) {
             System.out.printf("Please set the %s variable in your environment 
to match the location of the RocketMQ installation%n", 
MixAll.ROCKETMQ_HOME_ENV);
             System.exit(-2);
         }
 
-        log = LoggerFactory.getLogger(LoggerName.NAMESRV_LOGGER_NAME);
+        LOGGER = LoggerFactory.getLogger(LoggerName.NAMESRV_LOGGER_NAME);

Review Comment:
   I will



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to