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

[Dubbo-SPECIFY-ADDRESS] fix npe when zk push url #167

Merged
merged 2 commits into from
Nov 21, 2022

Conversation

wxbty
Copy link
Member

@wxbty wxbty commented Nov 11, 2022

Signed-off-by: x-shadow-man 1494445739@qq.com

What is the purpose of the change

bugfix of issue #166

Brief changelog

add npe judge, if null, reconstruct PathURLAddress obj

Verifying this change

Follow this checklist to help us incorporate your contribution quickly and easily:

  • Make sure there is a GITHUB_issue field 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.
  • [ x] Format the pull request title like [Dubbo-XXX] Fix UnknownException when host config not exist #XXX. Each commit
    in the pull request should have a meaningful subject line and body.
  • [x ] Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
  • Write necessary unit-test 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 sample
    in dubbo samples project.
  • [x ] Run mvn clean install -DskipTests=false & mvn clean test-compile failsafe:integration-test to make sure
    unit-test and integration-test pass.
  • [ x] If this contribution is large, please follow
    the Software Donation Guide.

Signed-off-by: x-shadow-man <1494445739@qq.com>
@codecov-commenter
Copy link

codecov-commenter commented Nov 12, 2022

Codecov Report

Merging #167 (b367d25) into master (b9a5f30) will decrease coverage by 6.15%.
The diff coverage is n/a.

@@             Coverage Diff              @@
##             master     #167      +/-   ##
============================================
- Coverage     39.67%   33.52%   -6.16%     
- Complexity      510      513       +3     
============================================
  Files           138      152      +14     
  Lines          4492     5349     +857     
  Branches        553      660     +107     
============================================
+ Hits           1782     1793      +11     
- Misses         2516     3360     +844     
- Partials        194      196       +2     
Impacted Files Coverage Δ
...ess/DefaultUserSpecifiedServiceAddressBuilder.java 82.85% <0.00%> (-17.15%) ⬇️
...gistry/nameservice/NameServiceRegistryFactory.java 0.00% <0.00%> (ø)
...apache/dubbo/rpc/rocketmq/codec/RocketMQCodec.java 0.00% <0.00%> (ø)
...e/dubbo/rpc/rocketmq/RocketMQProtocolConstant.java 0.00% <0.00%> (ø)
...bo/rpc/rocketmq/codec/DecodeableRpcInvocation.java 0.00% <0.00%> (ø)
...org/apache/dubbo/rpc/rocketmq/RocketMQChannel.java 0.00% <0.00%> (ø)
...dubbo/rpc/rocketmq/codec/RocketMQCodecSupport.java 0.00% <0.00%> (ø)
.../dubbo/rpc/rocketmq/codec/DecodeableRpcResult.java 0.00% <0.00%> (ø)
...rg/apache/dubbo/rpc/rocketmq/RocketMQProtocol.java 0.00% <0.00%> (ø)
...e/dubbo/rpc/rocketmq/codec/RocketMQCountCodec.java 0.00% <0.00%> (ø)
... and 6 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@wxbty
Copy link
Member Author

wxbty commented Nov 17, 2022

The test found that there was a problem with the previous one. We need to exclude the type of InstanceAddressURL. It will throw an exception when getUrlAddress. Now the dynamic change of ip can work normally.
please look again @AlbumenJ

Copy link
Member

@AlbumenJ AlbumenJ left a comment

Choose a reason for hiding this comment

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

LGTM

@AlbumenJ AlbumenJ merged commit ee1fef3 into apache:master Nov 21, 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.

3 participants