-
Notifications
You must be signed in to change notification settings - Fork 11.9k
[ISSUE #3173]Isolate Broker logs when multiple Broker services are deployed on the same machine. #3174
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
Conversation
…are deployed on the same machine
broker/src/main/java/org/apache/rocketmq/broker/BrokerStartup.java
Outdated
Show resolved
Hide resolved
Codecov Report
@@ Coverage Diff @@
## develop #3174 +/- ##
=============================================
+ Coverage 47.84% 49.15% +1.31%
+ Complexity 4555 3672 -883
=============================================
Files 552 312 -240
Lines 36642 29380 -7262
Branches 4848 4183 -665
=============================================
- Hits 17530 14441 -3089
+ Misses 16883 12972 -3911
+ Partials 2229 1967 -262
Continue to review full report at Codecov.
|
IMO, Could it be configured as optional? Otherwise, the sudden change of log directory is very confused for users. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IMO, Could it be configured as optional? Otherwise, the sudden change of log directory is very confused for users.
@RongtongJin @yuz10 can you review this pr again ? |
@@ -187,6 +187,13 @@ public static BrokerController createBrokerController(String[] args) { | |||
JoranConfigurator configurator = new JoranConfigurator(); | |||
configurator.setContext(lc); | |||
lc.reset(); | |||
System.setProperty("brokerLogDir", ""); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If it is set to "" here, will it be in the original directory by default?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, if brokerLogDir is "", the logPath in logback_broker.xml is default.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@@ -187,6 +187,8 @@ | |||
|
|||
private boolean autoDeleteUnusedStats = false; | |||
|
|||
private boolean isolateLogEnable = false; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be better to add some comments to explain the meaning of this parameter
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
[ISSUE apache#3173]Isolate Broker logs when multiple Broker services are deployed on the same machine.
[ISSUE apache#3173]Isolate Broker logs when multiple Broker services are deployed on the same machine.
Make sure set the target branch to
develop
What is the purpose of the change
#3173
Brief changelog
XX
Verifying this change
XXXX
Follow this checklist to help us incorporate your contribution quickly and easily. Notice,
it would be helpful if you could finish the following 5 checklist(the last one is not necessary)before request the community to review your PR
.[ISSUE #123] Fix UnknownException when host config not exist
. Each commit in the pull request should have a meaningful subject line and body.mvn -B clean apache-rat:check findbugs:findbugs checkstyle:checkstyle
to make sure basic checks pass. Runmvn clean install -DskipITs
to make sure unit-test pass. Runmvn clean test-compile failsafe:integration-test
to make sure integration-test pass.