diff --git a/collector/pkg/metadata/kubernetes/k8scache.go b/collector/pkg/metadata/kubernetes/k8scache.go index 2a45b13e9..db0c8f60a 100644 --- a/collector/pkg/metadata/kubernetes/k8scache.go +++ b/collector/pkg/metadata/kubernetes/k8scache.go @@ -292,8 +292,8 @@ func (c *K8sMetaDataCache) GetNodeNameByIp(ip string) (string, bool) { } func SetupCache(cache *K8sMetaDataCache, nodeMap *NodeMap, serviceMap *ServiceMap, rsMap *ReplicaSetMap) { - RLockDurningSetup() - defer RUnlockDurningSetup() + RLockForSetup() + defer RUnlockForSetup() if cache != nil { if cache.ContainerIdInfo != nil { // Recalculate local cacheMap