From 1b64965d8967a2abf8ba9794d166f767b2a8024e Mon Sep 17 00:00:00 2001 From: Matt Christiansen Date: Wed, 25 Aug 2021 18:11:19 -0700 Subject: [PATCH] Adding logging and making code look the same as create Signed-off-by: Matt Christiansen --- .../zookeepercluster/zookeepercluster_controller.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkg/controller/zookeepercluster/zookeepercluster_controller.go b/pkg/controller/zookeepercluster/zookeepercluster_controller.go index 1c8218c76..e59e8af19 100644 --- a/pkg/controller/zookeepercluster/zookeepercluster_controller.go +++ b/pkg/controller/zookeepercluster/zookeepercluster_controller.go @@ -237,7 +237,9 @@ func (r *ReconcileZookeeperCluster) reconcileStatefulSet(instance *zookeeperv1be return err } else { foundServiceAccount.ImagePullSecrets = serviceAccount.ImagePullSecrets - if err = r.client.Update(context.TODO(), foundServiceAccount); err != nil { + r.log.Info("Updating ServiceAccount", "ServiceAccount.Namespace", serviceAccount.Namespace, "ServiceAccount.Name", serviceAccount.Name) + err = r.client.Update(context.TODO(), foundServiceAccount) + if err != nil { return err } }