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

pickfirstleaf: minor simplification to reconcileSubConnsLocked method #7731

Merged
merged 1 commit into from
Oct 14, 2024

Conversation

easwars
Copy link
Contributor

@easwars easwars commented Oct 10, 2024

This PR adds a minor simplification to the reconcileSubConnsLocked method

  • Instead of building a new map for the existing subchannels with the key being the address and the value being a boolean (which is always set to true), we can instead use the existing map.

This PR also adds a docstring to the method instead of inline comments, some of which were a little stale.

RELEASE NOTES: none

@easwars easwars requested a review from arjan-bal October 10, 2024 23:43
@easwars easwars added the Type: Internal Cleanup Refactors, etc label Oct 10, 2024
@easwars easwars added this to the 1.68 Release milestone Oct 10, 2024
Copy link

codecov bot commented Oct 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 81.99%. Comparing base (b850ea5) to head (9e3a8f3).
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #7731      +/-   ##
==========================================
+ Coverage   81.96%   81.99%   +0.02%     
==========================================
  Files         362      362              
  Lines       28119    28116       -3     
==========================================
+ Hits        23048    23053       +5     
+ Misses       3863     3858       -5     
+ Partials     1208     1205       -3     
Files with missing lines Coverage Δ
balancer/pickfirst/pickfirstleaf/pickfirstleaf.go 88.88% <100.00%> (-0.13%) ⬇️

... and 15 files with indirect coverage changes

Copy link
Contributor

@arjan-bal arjan-bal left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@arjan-bal arjan-bal assigned easwars and unassigned arjan-bal Oct 11, 2024
@easwars easwars merged commit ad81c20 into grpc:master Oct 14, 2024
15 checks passed
janardhanvissa pushed a commit to janardhanvissa/grpc-go that referenced this pull request Oct 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants