rocketmq
rocketmq copied to clipboard
Replace byte array zeroing loop with Arrays.fill and specify charset in String construction
Which Issue(s) This PR Fixes
Fixes #9460
Brief Description
This PR improves code readability and portability by replacing manual byte array zeroing and by explicitly specifying a charset when converting bytes to string.
How Did You Test This Change?
These changes are refactorings that do not alter functionality. Existing unit tests continue to pass. Manual testing was also performed to ensure behavior remains consistent.
It would be better to create an issue first and link it to the PR. Additionally, it is recommended to write the title in English and follow the specified format.
It would be better to create an issue first and link it to the PR. Additionally, it is recommended to write the title in English and follow the specified format.
Thanks for your guidance!
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 48.00%. Comparing base (
53a3f69) to head (aa6586c).
Additional details and impacted files
@@ Coverage Diff @@
## develop #9458 +/- ##
=============================================
- Coverage 48.11% 48.00% -0.11%
+ Complexity 12015 11989 -26
=============================================
Files 1308 1308
Lines 92253 92252 -1
Branches 11808 11807 -1
=============================================
- Hits 44385 44288 -97
- Misses 42373 42454 +81
- Partials 5495 5510 +15
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.