Skip to content

Commit

Permalink
fix: memory leak related to k8s event broadcaster in lb watcher packa…
Browse files Browse the repository at this point in the history
…ge (#61)

Co-authored-by: Artashes Balabekyan <[email protected]>
  • Loading branch information
pogossian and artashesbalabekyan authored Mar 3, 2022
1 parent 820a9e8 commit 0c9ad45
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lbwatcher/lb_watcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,8 @@ func (w *Watcher) start() {
logger.Error(err, "")
}
cl := w.MGR.GetClient()
recorder, wtch, _ := eventRecorder(clientset)
recorder, wtch, broadcaster := eventRecorder(clientset)
defer broadcaster.Shutdown()
defer wtch.Stop()
w.loadBalancerProcess(clientset, cl, recorder)
}
Expand Down

0 comments on commit 0c9ad45

Please sign in to comment.