Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ISSUE #7425] Add RoccketmqControllerConsole log to print config to console #7458

Merged
merged 1 commit into from
Oct 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ public class LoggerName {
public static final String NAMESRV_LOGGER_NAME = "RocketmqNamesrv";
public static final String NAMESRV_CONSOLE_LOGGER_NAME = "RocketmqNamesrvConsole";
public static final String CONTROLLER_LOGGER_NAME = "RocketmqController";
public static final String CONTROLLER_CONSOLE_NAME = "RocketmqControllerConsole";
public static final String NAMESRV_WATER_MARK_LOGGER_NAME = "RocketmqNamesrvWaterMark";
public static final String BROKER_LOGGER_NAME = "RocketmqBroker";
public static final String BROKER_CONSOLE_NAME = "RocketmqConsole";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,10 @@ public static ControllerManager createControllerManager(String[] args) throws IO
}

if (commandLine.hasOption('p')) {
MixAll.printObjectProperties(null, controllerConfig);
MixAll.printObjectProperties(null, nettyServerConfig);
MixAll.printObjectProperties(null, nettyClientConfig);
Logger console = LoggerFactory.getLogger(LoggerName.CONTROLLER_CONSOLE_NAME);
MixAll.printObjectProperties(console, controllerConfig);
MixAll.printObjectProperties(console, nettyServerConfig);
MixAll.printObjectProperties(console, nettyClientConfig);
System.exit(0);
}

Expand Down
4 changes: 4 additions & 0 deletions controller/src/main/resources/rmq.controller.logback.xml
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,10 @@
<appender-ref ref="RocketmqControllerAppender"/>
</logger>

<logger name="RocketmqControllerConsole" additivity="false" level="INFO">
<appender-ref ref="STDOUT"/>
</logger>

<logger name="RocketmqCommon" additivity="false" level="INFO">
<appender-ref ref="RocketmqControllerAppender"/>
</logger>
Expand Down
Loading