Skip to content

Commit

Permalink
chore: change log level when patch core/repl node
Browse files Browse the repository at this point in the history
  • Loading branch information
Rory-Z committed Aug 17, 2023
1 parent 49ffc92 commit 2096214
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions controllers/apps/v2beta1/add_emqx_core.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ func (a *addCore) reconcile(ctx context.Context, instance *appsv2beta1.EMQX, _ i
)
if !patchResult.IsEmpty() {
logger := log.FromContext(ctx)
logger.V(1).Info("got different statefulSet for EMQX core nodes, will update statefulSet", "patch", string(patchResult.Patch))
logger.Info("got different statefulSet for EMQX core nodes, will update statefulSet", "patch", string(patchResult.Patch))

if err := a.Handler.Update(preSts); err != nil {
return subResult{err: emperror.Wrap(err, "failed to update statefulSet")}
Expand Down Expand Up @@ -146,7 +146,7 @@ func (a *addCore) getNewStatefulSet(ctx context.Context, instance *appsv2beta1.E
}

logger := log.FromContext(ctx)
logger.V(1).Info("got different pod template for EMQX core nodes, will create new statefulSet", "patch", string(patchResult.Patch))
logger.Info("got different pod template for EMQX core nodes, will create new statefulSet", "patch", string(patchResult.Patch))
return preSts, nil
}

Expand Down
4 changes: 2 additions & 2 deletions controllers/apps/v2beta1/add_emqx_repl.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ func (a *addRepl) reconcile(ctx context.Context, instance *appsv2beta1.EMQX, _ i
)
if !patchResult.IsEmpty() {
logger := log.FromContext(ctx)
logger.V(1).Info("got different replicaSet for EMQX replicant nodes, will update replicaSet", "patch", string(patchResult.Patch))
logger.Info("got different replicaSet for EMQX replicant nodes, will update replicaSet", "patch", string(patchResult.Patch))

if err := a.Handler.Update(preRs); err != nil {
return subResult{err: emperror.Wrap(err, "failed to update replicaSet")}
Expand Down Expand Up @@ -151,7 +151,7 @@ func (a *addRepl) getNewReplicaSet(ctx context.Context, instance *appsv2beta1.EM
return preRs, nil
}
logger := log.FromContext(ctx)
logger.V(1).Info("got different pod template for EMQX replicant nodes, will create new replicaSet", "patch", string(patchResult.Patch))
logger.Info("got different pod template for EMQX replicant nodes, will create new replicaSet", "patch", string(patchResult.Patch))

return preRs, nil
}
Expand Down

0 comments on commit 2096214

Please sign in to comment.