mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-11-13 06:04:02 +00:00
updates for ClusterController's maps were made without locking which can lead to race conditions which were detectede in https://github.com/kubernetes/kubernetes/issues/49958 This change adds a RWMutex to protect the data. We lock and unlock them whenever the data is accessed to make sure that we dont slow down too much. Signed-off-by: Daniel Dao <dqminh89@gmail.com>