Skip to content

Commit

Permalink
Eliminate possible deadlocks in ClusterCacheTracker
Browse files Browse the repository at this point in the history
Switch to a single lock in ClusterCacheTracker to eliminate possible
deadlocks when simultaneously deleted & recreating a client/cache for
the same cluster.

Signed-off-by: Andy Goldstein <goldsteina@vmware.com>
  • Loading branch information
ncdc committed Sep 18, 2020
1 parent b545ca1 commit f881755
Show file tree
Hide file tree
Showing 7 changed files with 406 additions and 911 deletions.
1 change: 1 addition & 0 deletions controllers/machinehealthcheck_controller.go
Expand Up @@ -404,6 +404,7 @@ func (r *MachineHealthCheckReconciler) watchClusterNodes(ctx context.Context, cl
}

if err := r.Tracker.Watch(ctx, remote.WatchInput{
Name: "machinehealthcheck-watchClusterNodes",
Cluster: util.ObjectKey(cluster),
Watcher: r.controller,
Kind: &corev1.Node{},
Expand Down

0 comments on commit f881755

Please sign in to comment.