Increase logging verbosity, restructure code

This commit is contained in:
Murat Kabilov
2017-05-12 11:41:28 +02:00
parent 3aaa05fb96
commit 79a6726d4d
7 changed files with 92 additions and 91 deletions
+2 -2
View File
@@ -56,7 +56,7 @@ func (c *Cluster) syncService() error {
}
desiredSvc := resources.Service(c.ClusterName(), c.Spec.TeamId, cSpec.AllowedSourceRanges)
if servicesEqual(c.Service, desiredSvc) {
if c.sameServiceWith(desiredSvc) {
return nil
}
c.logger.Infof("Service '%s' needs to be updated", util.NameFromMeta(desiredSvc.ObjectMeta))
@@ -100,7 +100,7 @@ func (c *Cluster) syncStatefulSet() error {
}
desiredSS := genStatefulSet(c.ClusterName(), cSpec, c.etcdHost, c.dockerImage)
equalSS, rollUpdate := statefulsetsEqual(c.Statefulset, desiredSS)
equalSS, rollUpdate := c.compareStatefulSetWith(desiredSS)
if equalSS {
return nil
}