forked from TrueCloudLab/frostfs-node
[#2165] services/tree: Allow to set custom synchronization interval
Signed-off-by: Evgenii Stratonikov <e.stratonikov@yadro.com>
This commit is contained in:
parent
6a4e5e6f0a
commit
d3054e577a
6 changed files with 37 additions and 7 deletions
|
@ -63,3 +63,11 @@ func (c TreeConfig) ReplicationChannelCapacity() int {
|
|||
func (c TreeConfig) ReplicationWorkerCount() int {
|
||||
return int(config.IntSafe(c.cfg, "replication_worker_count"))
|
||||
}
|
||||
|
||||
// SyncInterval returns the value of "sync_interval"
|
||||
// config parameter from the "tree" section.
|
||||
//
|
||||
// Returns 0 if config value is not specified.
|
||||
func (c TreeConfig) SyncInterval() time.Duration {
|
||||
return config.DurationSafe(c.cfg, "sync_interval")
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue