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

Fix remoteMap may be null to avoid NullPointerException being thrown(#7653) #7654

Merged
merged 1 commit into from
Apr 30, 2021

Conversation

skyguard1
Copy link
Contributor

What is the purpose of the change

In this issue(#7653 ) RemoteMap may be null, NullPointerException will be thrown in ClusterUtils, this pr is to fix this issue, to avoid throwing NullPointerException in ClusterUtils, thanks

Brief changelog

Verifying this change

  • 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.
  • 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.
  • 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.
  • Run mvn clean install -DskipTests=false & mvn clean test-compile failsafe:integration-test to make sure unit-test and integration-test pass.
  • If this contribution is large, please follow the Software Donation Guide.

@codecov-commenter
Copy link

codecov-commenter commented Apr 29, 2021

Codecov Report

Merging #7654 (cc9ed3a) into master (68062c1) will increase coverage by 0.04%.
The diff coverage is 50.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #7654      +/-   ##
============================================
+ Coverage     59.17%   59.21%   +0.04%     
  Complexity      529      529              
============================================
  Files          1076     1076              
  Lines         43451    43452       +1     
  Branches       6352     6353       +1     
============================================
+ Hits          25711    25731      +20     
+ Misses        14901    14877      -24     
- Partials       2839     2844       +5     
Impacted Files Coverage Δ Complexity Δ
...apache/dubbo/rpc/cluster/support/ClusterUtils.java 69.81% <50.00%> (-1.35%) 0.00 <0.00> (ø)
...he/dubbo/remoting/transport/netty/NettyServer.java 70.17% <0.00%> (-3.51%) 8.00% <0.00%> (-1.00%)
...c/main/java/org/apache/dubbo/rpc/RpcException.java 80.00% <0.00%> (-3.34%) 0.00% <0.00%> (ø%)
.../dubbo/remoting/transport/netty4/NettyChannel.java 61.38% <0.00%> (-2.98%) 0.00% <0.00%> (ø%)
...ava/org/apache/dubbo/config/ServiceConfigBase.java 59.63% <0.00%> (-0.61%) 0.00% <0.00%> (ø%)
...ubbo/registry/client/ServiceDiscoveryRegistry.java 42.26% <0.00%> (-0.60%) 0.00% <0.00%> (ø%)
...ng/transport/dispatcher/all/AllChannelHandler.java 89.65% <0.00%> (ø) 0.00% <0.00%> (ø%)
...apache/dubbo/common/extension/ExtensionLoader.java 78.39% <0.00%> (+0.22%) 0.00% <0.00%> (ø%)
...he/dubbo/registry/multicast/MulticastRegistry.java 69.30% <0.00%> (+0.93%) 0.00% <0.00%> (ø%)
...pache/dubbo/registry/support/AbstractRegistry.java 80.74% <0.00%> (+1.11%) 0.00% <0.00%> (ø%)
... and 3 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 68062c1...cc9ed3a. Read the comment docs.

@AlbumenJ AlbumenJ merged commit ed1d357 into apache:master Apr 30, 2021
goodjava pushed a commit to WZD-MI/incubator-dubbo that referenced this pull request May 6, 2021
…pache#7654)

Signed-off-by: xingrufei <xingrufei@sogou-inc.com>

Co-authored-by: xingrufei <xingrufei@sogou-inc.com>
AlbumenJ added a commit to AlbumenJ/dubbo that referenced this pull request May 28, 2021
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.

None yet

3 participants