mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 11:50:44 +00:00
Merge pull request #8498 from justinsb/proxier_lock_cleanupstalestickysessions
Add mutex lock to cleanupStaleStickySessions
This commit is contained in:
commit
9f808d8e16
@ -154,6 +154,8 @@ func (proxier *Proxier) ensurePortals() {
|
|||||||
|
|
||||||
// clean up any stale sticky session records in the hash map.
|
// clean up any stale sticky session records in the hash map.
|
||||||
func (proxier *Proxier) cleanupStaleStickySessions() {
|
func (proxier *Proxier) cleanupStaleStickySessions() {
|
||||||
|
proxier.mu.Lock()
|
||||||
|
defer proxier.mu.Unlock()
|
||||||
for name := range proxier.serviceMap {
|
for name := range proxier.serviceMap {
|
||||||
proxier.loadBalancer.CleanupStaleStickySessions(name)
|
proxier.loadBalancer.CleanupStaleStickySessions(name)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user