Browse Source

comment change: 3 times of the pulse

pull/2/head
Chris Lu 12 years ago
parent
commit
ccab4217e4
  1. 2
      weed-fs/src/pkg/topology/topology_event_handling.go

2
weed-fs/src/pkg/topology/topology_event_handling.go

@ -10,7 +10,7 @@ import (
func (t *Topology) StartRefreshWritableVolumes() { func (t *Topology) StartRefreshWritableVolumes() {
go func() { go func() {
for { for {
freshThreshHold := time.Now().Unix() - 3*t.pulse //5 times of sleep interval
freshThreshHold := time.Now().Unix() - 3*t.pulse //3 times of sleep interval
t.CollectDeadNodeAndFullVolumes(freshThreshHold, t.volumeSizeLimit) t.CollectDeadNodeAndFullVolumes(freshThreshHold, t.volumeSizeLimit)
time.Sleep(time.Duration(float32(t.pulse*1e3)*(1+rand.Float32())) * time.Millisecond) time.Sleep(time.Duration(float32(t.pulse*1e3)*(1+rand.Float32())) * time.Millisecond)
} }

Loading…
Cancel
Save