Skip to content
Snippets Groups Projects
Commit a8ed1e25 authored by Oleksii Kliukin's avatar Oleksii Kliukin Committed by GitHub
Browse files

Avoid re-creating master pod if it is empty during sync. (#58)

Fixes #59 
parent 00150711
Branches
Tags
No related merge requests found
......@@ -140,8 +140,7 @@ func (c *Cluster) recreatePods() error {
}
if masterPod.Name == "" {
c.logger.Warningln("No master pod in the cluster")
}
} else {
//TODO: do manual failover
//TODO: specify master, leave new master empty
c.logger.Infof("Recreating master pod '%s'", util.NameFromMeta(masterPod.ObjectMeta))
......@@ -149,6 +148,7 @@ func (c *Cluster) recreatePods() error {
if err := c.recreatePod(masterPod); err != nil {
return fmt.Errorf("could not recreate master pod '%s': %v", util.NameFromMeta(masterPod.ObjectMeta), err)
}
}
return nil
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment