core: reschedule the next persist in a second from previous one
It makes little sense queueing up several persistence goroutines (or actually even running them concurrently).
This commit is contained in:
parent
cad1f074d4
commit
b49808b766
1 changed files with 1 additions and 1 deletions
|
@ -278,8 +278,8 @@ func (bc *Blockchain) Run() {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
bc.log.Warn("failed to persist blockchain", zap.Error(err))
|
bc.log.Warn("failed to persist blockchain", zap.Error(err))
|
||||||
}
|
}
|
||||||
|
persistTimer.Reset(persistInterval)
|
||||||
}()
|
}()
|
||||||
persistTimer.Reset(persistInterval)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue