diff --git a/cluster/datastore.go b/cluster/datastore.go index 47bfd89ba..cae6b8820 100644 --- a/cluster/datastore.go +++ b/cluster/datastore.go @@ -119,19 +119,8 @@ func (d *Datastore) watchChanges() error { func (d *Datastore) reload() error { log.Debug("Datastore reload") - d.localLock.Lock() - err := d.kv.LoadConfig(d.meta) - if err != nil { - d.localLock.Unlock() - return err - } - err = d.meta.unmarshall() - if err != nil { - d.localLock.Unlock() - return err - } - d.localLock.Unlock() - return nil + _, err := d.Load() + return err } // Begin creates a transaction with the KV store.