Add SyncInterval and NodeRecoverTimeout to cluster config

This commit is contained in:
Ingo Oppermann
2023-06-07 10:18:23 +02:00
parent ae84fd1d21
commit bd75a5ad0f
5 changed files with 35 additions and 23 deletions

View File

@@ -113,6 +113,9 @@ type cluster struct {
shutdownCh chan struct{}
shutdownLock sync.Mutex
syncInterval time.Duration
nodeRecoverTimeout time.Duration
forwarder forwarder.Forwarder
api API
proxy proxy.Proxy
@@ -140,6 +143,9 @@ func New(config ClusterConfig) (Cluster, error) {
shutdownCh: make(chan struct{}),
syncInterval: config.SyncInterval,
nodeRecoverTimeout: config.NodeRecoverTimeout,
nodes: map[string]proxy.Node{},
}