Browse Source

Fixes race with unlocked setter. (#5532)

pull/5536/head
M@ 8 months ago
committed by GitHub
parent
commit
855607c536
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 2
      weed/cluster/lock_manager/lock_ring.go

2
weed/cluster/lock_manager/lock_ring.go

@ -72,7 +72,9 @@ func (r *LockRing) SetSnapshot(servers []pb.ServerAddress) {
return servers[i] < servers[j]
})
r.Lock()
r.lastUpdateTime = time.Now()
r.Unlock()
r.addOneSnapshot(servers)

Loading…
Cancel
Save