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

roundrobin: Delegate subchannel creation to pickfirst #7966

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

arjan-bal
Copy link
Contributor

@arjan-bal arjan-bal commented Dec 24, 2024

This PR switches round round robin to defer to pick first instead of creating and handling SubConns itself. This is part of DualStack, and makes this a petiole. This PR makes roundrobin a wrapper around the endpoint sharding policy that implements the roundrobin logic.

RELEASE NOTES:

  • balancer/roundrobin: Round Robin uses pick first child policies to manage endpoints instead of creating SubConns.
  • balancer/roundrobin: Round Robin uses the Endpoints field instead of the Addresses field in resolver state updates.

@arjan-bal arjan-bal added Type: Feature New features or improvements in behavior Area: Resolvers/Balancers Includes LB policy & NR APIs, resolver/balancer/picker wrappers, LB policy impls and utilities. labels Dec 24, 2024
@arjan-bal arjan-bal added this to the 1.70 Release milestone Dec 24, 2024
@arjan-bal arjan-bal changed the title roundrobin: Delegate subchannel endpoint to pickfirst roundrobin: Delegate subchannel creation to pickfirst Dec 24, 2024
Copy link

codecov bot commented Dec 24, 2024

Codecov Report

Attention: Patch coverage is 87.03704% with 7 lines in your changes missing coverage. Please review.

Project coverage is 81.99%. Comparing base (724f450) to head (3a594f6).

Files with missing lines Patch % Lines
balancer/roundrobin/roundrobin.go 78.12% 5 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #7966      +/-   ##
==========================================
- Coverage   82.05%   81.99%   -0.06%     
==========================================
  Files         381      381              
  Lines       38539    38558      +19     
==========================================
- Hits        31622    31616       -6     
- Misses       5602     5633      +31     
+ Partials     1315     1309       -6     
Files with missing lines Coverage Δ
balancer/pickfirst/pickfirstleaf/pickfirstleaf.go 87.25% <100.00%> (-0.03%) ⬇️
balancer/weightedroundrobin/balancer.go 82.92% <100.00%> (-0.79%) ⬇️
internal/testutils/balancer.go 87.11% <100.00%> (+4.76%) ⬆️
internal/testutils/wrr.go 91.30% <100.00%> (+1.30%) ⬆️
balancer/roundrobin/roundrobin.go 77.14% <78.12%> (-22.86%) ⬇️

... and 26 files with indirect coverage changes

@arjan-bal arjan-bal force-pushed the roundrobin-delegate-to-pf branch from 01ef7af to 3a594f6 Compare December 26, 2024 03:52
@arjan-bal arjan-bal requested a review from dfawley December 26, 2024 03:52
@arjan-bal arjan-bal added Type: Internal Cleanup Refactors, etc and removed Type: Feature New features or improvements in behavior labels Dec 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Resolvers/Balancers Includes LB policy & NR APIs, resolver/balancer/picker wrappers, LB policy impls and utilities. Type: Internal Cleanup Refactors, etc
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants