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

optimize: let DefaultCoordinator invoke NettyRemotingServer 's close() method #4300

Merged

Conversation

Pinocchio2018
Copy link
Contributor

@Pinocchio2018 Pinocchio2018 commented Jan 16, 2022

  • I have registered the PR changes.

Ⅰ. Describe what this PR did

let DefaultCoordinator invoke NettyRemotingServer 's close() method, no longer invoked by ServerRunner
to avoid RegistryService 's close() invoked twice

Ⅱ. Does this pull request fix one issue?

fixes #4172

Ⅲ. Why don't you add test cases (unit test/integration test)?

Ⅳ. Describe how to verify it

Ⅴ. Special notes for reviews

@Pinocchio2018 Pinocchio2018 force-pushed the develop_redis注册中心下线异常 branch from 34ea0e6 to 7403fdc Compare January 16, 2022 14:21
@codecov-commenter
Copy link

codecov-commenter commented Jan 16, 2022

Codecov Report

Merging #4300 (7c5e979) into develop (d6efb49) will decrease coverage by 0.01%.
The diff coverage is 42.85%.

❗ Current head 7c5e979 differs from pull request most recent head 1afa55d. Consider uploading reports for the commit 1afa55d to get more accurate results
Impacted file tree graph

@@              Coverage Diff              @@
##             develop    #4300      +/-   ##
=============================================
- Coverage      48.54%   48.53%   -0.02%     
+ Complexity      3794     3791       -3     
=============================================
  Files            724      724              
  Lines          24239    24244       +5     
  Branches        2970     2971       +1     
=============================================
  Hits           11767    11767              
- Misses         11230    11234       +4     
- Partials        1242     1243       +1     
Impacted Files Coverage Δ
.../io/seata/core/rpc/netty/NettyServerBootstrap.java 0.00% <ø> (ø)
...o/seata/discovery/registry/RegistryHeartBeats.java 0.00% <0.00%> (ø)
...o/seata/server/coordinator/DefaultCoordinator.java 49.21% <60.00%> (+0.28%) ⬆️
...n/src/main/java/io/seata/common/util/IdWorker.java 77.08% <0.00%> (-6.25%) ⬇️

@Pinocchio2018 Pinocchio2018 force-pushed the develop_redis注册中心下线异常 branch from 7403fdc to 66c2055 Compare January 16, 2022 14:56
@Pinocchio2018 Pinocchio2018 changed the title optimize seata server shutdown when using redis as registry center optimize let DefaultCoordinator close RegistryService not NettyRemotingServer Jan 16, 2022
@Pinocchio2018 Pinocchio2018 changed the title optimize let DefaultCoordinator close RegistryService not NettyRemotingServer optimize let DefaultCoordinator invoke NettyRemotingServer 's close() method Jan 16, 2022
@Pinocchio2018 Pinocchio2018 force-pushed the develop_redis注册中心下线异常 branch from 1afa55d to 346b2b6 Compare January 16, 2022 15:29
Copy link
Contributor

@funky-eyes funky-eyes left a comment

Choose a reason for hiding this comment

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

LGTM

@funky-eyes funky-eyes added this to the 1.5.0 milestone Jan 17, 2022
@funky-eyes funky-eyes changed the title optimize let DefaultCoordinator invoke NettyRemotingServer 's close() method optimize: let DefaultCoordinator invoke NettyRemotingServer 's close() method Jan 17, 2022
@funky-eyes funky-eyes merged commit 11d3478 into apache:develop Jan 17, 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.

close() method in RedisRegistryServiceImpl was invoked twice during seata server shutting down
3 participants