From 3f931b94f4356622d91853a14dc9f68ccbb37c19 Mon Sep 17 00:00:00 2001 From: Jaganathan P <156800415+jagan2221@users.noreply.github.com> Date: Fri, 30 Aug 2024 16:22:22 +0530 Subject: [PATCH] Update opamp_agent.go --- pkg/extension/opampextension/opamp_agent.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkg/extension/opampextension/opamp_agent.go b/pkg/extension/opampextension/opamp_agent.go index 3838d2eeaa..3dfa4ead33 100644 --- a/pkg/extension/opampextension/opamp_agent.go +++ b/pkg/extension/opampextension/opamp_agent.go @@ -484,7 +484,7 @@ func (o *opampAgent) composeEffectiveConfig() *protobufs.EffectiveConfig { } func (o *opampAgent) applyRemoteConfig(config *protobufs.AgentRemoteConfig) (configChanged bool, err error) { - o.logger.Debug("Received remote config from OpAMP server", zap.ByteString("hash", config.ConfigHash)) + o.logger.Info("Received remote config from OpAMP server", zap.ByteString("hash", config.ConfigHash)) if !o.cfg.AcceptsRemoteConfiguration { return false, fmt.Errorf("OpAMP agent does not accept remote configuration") @@ -501,6 +501,8 @@ func (o *opampAgent) applyRemoteConfig(config *protobufs.AgentRemoteConfig) (con } fb, err := k.Marshal(yaml.Parser()) + o.logger.Info("Agent config yaml", zap.String("config", string(fb))) + if err != nil { return false, fmt.Errorf("cannot marshal config named %s: %v", n, err) }