Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

xds/balancer/priority: Unlock mutex before returning #7417

Merged
merged 1 commit into from
Jul 15, 2024

Conversation

arjan-bal
Copy link
Contributor

@arjan-bal arjan-bal commented Jul 15, 2024

Release the mutex that is locked a couple of lines above.

b.mu.Lock()
if b.done.HasFired() {
return
}

This could subsequent calls to UpdateClientConnState to get stuck.

RELEASE NOTES: None

@arjan-bal arjan-bal requested a review from dfawley July 15, 2024 14:58
@arjan-bal arjan-bal added this to the 1.66 Release milestone Jul 15, 2024
Copy link

codecov bot commented Jul 15, 2024

Codecov Report

Attention: Patch coverage is 0% with 1 line in your changes missing coverage. Please review.

Project coverage is 81.33%. Comparing base (bdd707e) to head (040de9b).
Report is 14 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #7417      +/-   ##
==========================================
- Coverage   81.42%   81.33%   -0.09%     
==========================================
  Files         348      350       +2     
  Lines       26744    26846     +102     
==========================================
+ Hits        21775    21834      +59     
- Misses       3779     3809      +30     
- Partials     1190     1203      +13     
Files Coverage Δ
xds/internal/balancer/priority/balancer.go 87.82% <0.00%> (-0.78%) ⬇️

... and 32 files with indirect coverage changes

@dfawley
Copy link
Member

dfawley commented Jul 15, 2024

This could subsequent calls to UpdateClientConnState to get stuck.

Calling a Closed Balancer would be illegal, and isn't something we should ever do anywhere for any reason.

@dfawley dfawley changed the title priority: Unlock mutex before returning xds/balancer/priority: Unlock mutex before returning Jul 15, 2024
@dfawley dfawley merged commit 700ca74 into grpc:master Jul 15, 2024
13 checks passed
printchard pushed a commit to printchard/grpc-go that referenced this pull request Jul 30, 2024
printchard pushed a commit to printchard/grpc-go that referenced this pull request Jul 30, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 12, 2025
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants