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

[Summer of code] Fix controller bugs #4399

Merged

Conversation

hzh0425
Copy link
Member

@hzh0425 hzh0425 commented Jun 1, 2022

Make sure set the target branch to develop

What is the purpose of the change

Tracking issue: #4330
Fix some bugs for controller mode.

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.

  • Make sure there is a Github issue filed for the change (usually before you start working on it). Trivial changes like typos do not require a Github issue. Your pull request should address just this issue, without pulling in other changes - one PR resolves one issue.
  • Format the pull request title like [ISSUE #123] Fix UnknownException when host config not exist. Each commit in the pull request should have a meaningful subject line and body.
  • Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
  • Write necessary unit-test(over 80% coverage) to verify your logic correction, more mock a little better when cross module dependency exist. If the new feature or significant change is committed, please remember to add integration-test in test module.
  • Run mvn -B clean apache-rat:check findbugs:findbugs checkstyle:checkstyle to make sure basic checks pass. Run mvn clean install -DskipITs to make sure unit-test pass. Run mvn clean test-compile failsafe:integration-test to make sure integration-test pass.
  • If this contribution is large, please file an Apache Individual Contributor License Agreement.

LOGGER.info("Receive slave handshake, slaveId:{}, slaveAddress:{}, isSyncFromLastFile:{}, isAsyncLearner:{}",
AutoSwitchHAConnection.this.slaveId, AutoSwitchHAConnection.this.slaveAddress,
AutoSwitchHAConnection.this.isSyncFromLastFile, AutoSwitchHAConnection.this.isAsyncLearner);
case HANDSHAKE: {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

不需要大括号

@coveralls
Copy link

coveralls commented Jun 1, 2022

Coverage Status

Coverage increased (+0.01%) to 47.517% when pulling f8a0ac8 on hzh0425:fix-controller-bug into 6f3b372 on apache:5.0.0-beta-dledger-controller.

@RongtongJin
Copy link
Contributor

Good catch! A very insidious bug was found!

@codecov-commenter
Copy link

Codecov Report

Merging #4399 (f8a0ac8) into 5.0.0-beta-dledger-controller (6f3b372) will decrease coverage by 0.03%.
The diff coverage is 58.27%.

@@                         Coverage Diff                         @@
##             5.0.0-beta-dledger-controller    #4399      +/-   ##
===================================================================
- Coverage                            43.31%   43.27%   -0.04%     
+ Complexity                            6337     6331       -6     
===================================================================
  Files                                  839      839              
  Lines                                59625    59640      +15     
  Branches                              8123     8130       +7     
===================================================================
- Hits                                 25826    25812      -14     
- Misses                               30455    30478      +23     
- Partials                              3344     3350       +6     
Impacted Files Coverage Δ
...java/org/apache/rocketmq/broker/BrokerStartup.java 7.64% <0.00%> (-0.05%) ⬇️
...e/rocketmq/container/BrokerContainerProcessor.java 4.16% <0.00%> (-0.03%) ⬇️
.../apache/rocketmq/store/ha/DefaultHAConnection.java 65.86% <0.00%> (-1.35%) ⬇️
...che/rocketmq/container/BrokerContainerStartup.java 57.20% <28.57%> (-0.25%) ⬇️
...java/org/apache/rocketmq/store/ha/io/HAWriter.java 61.90% <50.00%> (+7.73%) ⬆️
...ketmq/store/ha/autoswitch/AutoSwitchHAService.java 56.00% <55.55%> (+0.05%) ⬆️
...cketmq/store/ha/autoswitch/AutoSwitchHAClient.java 75.47% <70.68%> (-0.11%) ⬇️
...mq/store/ha/autoswitch/AutoSwitchHAConnection.java 73.33% <77.77%> (-0.87%) ⬇️
...apache/rocketmq/broker/longpolling/PopRequest.java 31.03% <0.00%> (-13.80%) ⬇️
...ache/rocketmq/common/stats/MomentStatsItemSet.java 39.13% <0.00%> (-4.35%) ⬇️
... and 19 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6f3b372...f8a0ac8. Read the comment docs.

@RongtongJin RongtongJin merged commit 99d77df into apache:5.0.0-beta-dledger-controller Jun 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants