Skip to content

Commit

Permalink
Revert "[release-19.0] VTTablet: smartconnpool: notify all expired wa…
Browse files Browse the repository at this point in the history
…iters (vitessio#16897) (vitessio#16901)"

This reverts commit 805d607.
  • Loading branch information
mhamza15 committed Jan 23, 2025
1 parent 9b1f5c0 commit 5ea5d20
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 72 deletions.
5 changes: 1 addition & 4 deletions go/pools/smartconnpool/waitlist.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,14 +88,11 @@ func (wl *waitlist[C]) expire(force bool) {
// or remove everything if force is true
for e := wl.list.Front(); e != nil; e = e.Next() {
if force || e.Value.ctx.Err() != nil {
wl.list.Remove(e)
expired = append(expired, e)
continue
}
}
// remove the expired waiters from the waitlist after traversing it
for _, e := range expired {
wl.list.Remove(e)
}
wl.mu.Unlock()

// once all the expired waiters have been removed from the waitlist, wake them up one by one
Expand Down
68 changes: 0 additions & 68 deletions go/pools/smartconnpool/waitlist_test.go

This file was deleted.

0 comments on commit 5ea5d20

Please sign in to comment.