Browse Source

bugfix: unregister ec shards when volume server disconnected (#5697)

bugfix unregister ec shards when volume server disconnected

Co-authored-by: liguowei <liguowei@xinye.com>
pull/5701/head
Numblgw 6 months ago
committed by GitHub
parent
commit
73baf82f05
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 5
      weed/topology/topology_event_handling.go

5
weed/topology/topology_event_handling.go

@ -90,6 +90,11 @@ func (t *Topology) UnRegisterDataNode(dn *DataNode) {
vl.SetVolumeUnavailable(dn, v.Id)
}
// unregister ec shards when volume server disconnected
for _, s := range dn.GetEcShards() {
t.UnRegisterEcShards(s, dn)
}
negativeUsages := dn.GetDiskUsages().negative()
dn.UpAdjustDiskUsageDelta(negativeUsages)
dn.DeltaUpdateVolumes([]storage.VolumeInfo{}, dn.GetVolumes())

Loading…
Cancel
Save