Skip to content

[ISSUE #2082] Use StringBuilder instead of StringBuffer.#2087

Merged
RongtongJin merged 2 commits into
apache:developfrom
RosaDreaming:bug_fix
Jun 15, 2020
Merged

[ISSUE #2082] Use StringBuilder instead of StringBuffer.#2087
RongtongJin merged 2 commits into
apache:developfrom
RosaDreaming:bug_fix

Conversation

@RosaDreaming
Copy link
Copy Markdown
Contributor

What is the purpose of the change

replace StringBuffer to StringBulder

Brief changelog

replace StringBuffer to StringBulder

Verifying this change

replace StringBuffer to StringBulder

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 StringBuffer or StringBuilder 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.

@coveralls
Copy link
Copy Markdown

Coverage Status

Coverage decreased (-0.07%) to 51.213% when pulling c62e92f on RosaDreaming:bug_fix into b5a07c1 on apache:develop.

@codecov-commenter
Copy link
Copy Markdown

Codecov Report

Merging #2087 into develop will increase coverage by 0.32%.
The diff coverage is 83.33%.

Impacted file tree graph

@@              Coverage Diff              @@
##             develop    #2087      +/-   ##
=============================================
+ Coverage      45.07%   45.40%   +0.32%     
- Complexity      4195     4241      +46     
=============================================
  Files            545      545              
  Lines          35728    35843     +115     
  Branches        4744     4762      +18     
=============================================
+ Hits           16103    16273     +170     
+ Misses         17576    17520      -56     
- Partials        2049     2050       +1     
Impacted Files Coverage Δ Complexity Δ
...apache/rocketmq/common/protocol/NamespaceUtil.java 54.83% <83.33%> (ø) 22.00 <0.00> (ø)
...ache/rocketmq/common/stats/MomentStatsItemSet.java 43.47% <0.00%> (-12.78%) 6.00% <0.00%> (+1.00%) ⬇️
...org/apache/rocketmq/common/stats/StatsItemSet.java 38.09% <0.00%> (-9.43%) 12.00% <0.00%> (ø%)
...nt/impl/consumer/ConsumeMessageOrderlyService.java 38.98% <0.00%> (-2.53%) 16.00% <0.00%> (-3.00%)
...in/java/org/apache/rocketmq/test/util/MQAdmin.java 38.88% <0.00%> (-1.12%) 7.00% <0.00%> (ø%)
...broker/processor/AbstractSendMessageProcessor.java 40.58% <0.00%> (-0.49%) 15.00% <0.00%> (ø%)
...e/rocketmq/remoting/netty/NettyRemotingClient.java 46.92% <0.00%> (-0.28%) 26.00% <0.00%> (ø%)
...c/main/java/org/apache/rocketmq/common/MixAll.java 42.79% <0.00%> (-0.27%) 26.00% <0.00%> (-1.00%)
...g/apache/rocketmq/client/impl/MQClientAPIImpl.java 12.63% <0.00%> (-0.18%) 25.00% <0.00%> (ø%)
... and 34 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 bc692b4...c62e92f. Read the comment docs.

@ShannonDing ShannonDing changed the title StringBuffer or StringBuilder pr [ISSUE #2082] Use StringBuilder instead of StringBuffer. Jun 12, 2020
@RongtongJin RongtongJin merged commit 2fa51fc into apache:develop Jun 15, 2020
@RongtongJin RongtongJin added this to the 4.8.0 milestone Jun 15, 2020
@RongtongJin RongtongJin linked an issue Jun 15, 2020 that may be closed by this pull request
RongtongJin pushed a commit that referenced this pull request Jun 24, 2020
* stringbuilder replace

Co-authored-by: qunlin.yi <qunlin.yi@beibei.com>
tandan330 pushed a commit to tandan330/rocketmq that referenced this pull request Jun 29, 2020
* ORIGN-develop: (326 commits)
  [maven-release-plugin] prepare for next development iteration
  [maven-release-plugin] prepare release rocketmq-all-4.7.1
  chore(release):prepare to release RocketMQ 4.7.1
  [ISSUE apache#2118] Fix AdminBrokerProcessorTest can not pass when machine's hostname contains illegal characters
  [ISSUE apache#2088] Optimize rocketmq client's stats of RT to make sense
  [ISSUE apache#2082] Use StringBuilder instead of StringBuffer. (apache#2087)
  [ISSUE apache#2085]support graceful shutdown push consumer (apache#2084)
  [ISSUE#2078] HmacSHA1 not avaliable when use openjdk
  [ISSUE apache#1976]System topic should add permission checking globally (apache#1985)
  [ISSUE apache#1931] Remove duplicated doAfterRpcHooks logic
  [ISSUE apache#2044] Fix DefaultLitePullConsumerImpl NPE (apache#2059)
  Fix Fastjson version for RCE problem
  [ISSUE apache#1988] Fix the issue that can not update messageDelay correctly with mqadmin updateBrokerConfig command
  Add @OverRide for RMQOrderListener.java (apache#1939)
  Init english version of the README
  Fix typo in README
  select a new namesrv when namesrvAddrChoosed not in new addr list
  npe fix
  comment fix
  [ISSUE apache#1689]add interfaces to remove unused statsItems in BrokerStatsManager. (apache#2029)
  ...

# Conflicts:
#	client/src/test/java/org/apache/rocketmq/client/impl/consumer/ConsumeMessageOrderlyServiceTest.java
GenerousMan pushed a commit to GenerousMan/rocketmq that referenced this pull request Aug 12, 2022
…e#2087)

* stringbuilder replace

Co-authored-by: qunlin.yi <qunlin.yi@beibei.com>
pulllock pushed a commit to pulllock/rocketmq that referenced this pull request Oct 19, 2023
…e#2087)

* stringbuilder replace

Co-authored-by: qunlin.yi <qunlin.yi@beibei.com>
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.

StringBuffer or StringBuilder

6 participants