dubbo icon indicating copy to clipboard operation
dubbo copied to clipboard

Fix issue 15678 Key no longer appear in exception messages

Open qxggg opened this issue 3 weeks ago • 2 comments

What is the purpose of the change?

see #15678 This change introduces support for masking sensitive parameters when building URL strings in Dubbo. Previously, parameters such as password, secretKey, or other user-defined sensitive fields could be exposed in logs or configuration outputs. The update ensures that: 1. Sensitive parameter names can be configured through dubbo.url.sensitive-parameter-names. 2. Any parameter matching the sensitive list is automatically excluded when the URL string is generated. 3. The behavior is covered by unit tests, ensuring consistent functionality and preventing regressions.

Checklist

  • [x] Make sure there is a GitHub_issue field for the change.
  • [x] Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
  • [x] Write necessary unit-test to verify your logic correction. If the new feature or significant change is committed, please remember to add sample in dubbo samples project.
  • [x] Make sure gitHub actions can pass. Why the workflow is failing and how to fix it?

qxggg avatar Nov 29 '25 07:11 qxggg

Codecov Report

:x: Patch coverage is 93.75000% with 1 line in your changes missing coverage. Please review. :white_check_mark: Project coverage is 60.78%. Comparing base (efed26c) to head (d2ad082).

Files with missing lines Patch % Lines
...mon/src/main/java/org/apache/dubbo/common/URL.java 75.00% 0 Missing and 1 partial :warning:
Additional details and impacted files
@@            Coverage Diff            @@
##                3.3   #15812   +/-   ##
=========================================
  Coverage     60.77%   60.78%           
- Complexity    11710    11721   +11     
=========================================
  Files          1938     1938           
  Lines         88692    88707   +15     
  Branches      13387    13391    +4     
=========================================
+ Hits          53903    53917   +14     
+ Misses        29260    29254    -6     
- Partials       5529     5536    +7     
Flag Coverage Δ
integration-tests-java21 32.49% <56.25%> (+0.12%) :arrow_up:
integration-tests-java8 32.39% <56.25%> (-0.05%) :arrow_down:
samples-tests-java21 32.00% <56.25%> (+0.03%) :arrow_up:
samples-tests-java8 29.74% <56.25%> (+0.04%) :arrow_up:
unit-tests-java11 59.09% <93.75%> (+0.02%) :arrow_up:
unit-tests-java17 58.57% <87.50%> (+<0.01%) :arrow_up:
unit-tests-java21 58.59% <87.50%> (-0.01%) :arrow_down:
unit-tests-java25 58.53% <87.50%> (+0.01%) :arrow_up:
unit-tests-java8 59.10% <93.75%> (+0.05%) :arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

: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.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov-commenter avatar Nov 29 '25 08:11 codecov-commenter

@oxsean @zrlw @RainYuY I simplified and revised the previous PR implementation by others and rewrote the test cases. Could you please take a look when you have time and let me know if it meets your original requirements?

qxggg avatar Dec 03 '25 08:12 qxggg

@oxsean @zrlw @RainYuY Could you please take a look when you have time? Thank you!

qxggg avatar Dec 19 '25 13:12 qxggg