From aa84635aa11b7d8b8fd70a261c036531899b58d4 Mon Sep 17 00:00:00 2001 From: Travis Raines <571832+rainest@users.noreply.github.com> Date: Tue, 23 Jul 2024 18:43:54 -0700 Subject: [PATCH] chore(kongstate) update logging var Convert some logs to use the logging package. These lines were moved elsewhere in a feature commit in main, so they weren't updated by 6dd9031cf89c43a2f1d9d1daf4a7849b203f8144 in the 3.2.x branch. --- internal/dataplane/kongstate/kongstate.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/internal/dataplane/kongstate/kongstate.go b/internal/dataplane/kongstate/kongstate.go index 980de86d77..ef162e686e 100644 --- a/internal/dataplane/kongstate/kongstate.go +++ b/internal/dataplane/kongstate/kongstate.go @@ -823,7 +823,7 @@ func (ks *KongState) fillCustomEntityForeignFields( if !ok { return } - logger.V(util.DebugLevel).Info("fetch references via plugin", "plugin_key", pluginKey) + logger.V(logging.DebugLevel).Info("fetch references via plugin", "plugin_key", pluginKey) // Traverse through the fields of the entity and fill the "foreign" fields with IDs of referring entities. // Note: this procedure will make referred services'/routes'/consumers' ID to be filled. @@ -841,7 +841,7 @@ func (ks *KongState) fillCustomEntityForeignFields( parsedEntity[fieldName] = map[string]interface{}{ "id": serviceIDs[0], } - logger.V(util.DebugLevel).Info("added ref to service", "service_id", serviceIDs[0]) + logger.V(logging.DebugLevel).Info("added ref to service", "service_id", serviceIDs[0]) } case string(kong.EntityTypeRoutes): routeIDs := lo.FilterMap(rels.Routes, func(r *Route, _ int) (string, bool) { @@ -854,7 +854,7 @@ func (ks *KongState) fillCustomEntityForeignFields( parsedEntity[fieldName] = map[string]interface{}{ "id": routeIDs[0], } - logger.V(util.DebugLevel).Info("added ref to route", "route_id", routeIDs[0]) + logger.V(logging.DebugLevel).Info("added ref to route", "route_id", routeIDs[0]) } case string(kong.EntityTypeConsumers): consumerIDs := lo.FilterMap(rels.Consumers, func(c *Consumer, _ int) (string, bool) { @@ -867,7 +867,7 @@ func (ks *KongState) fillCustomEntityForeignFields( parsedEntity[fieldName] = map[string]interface{}{ "id": consumerIDs[0], } - logger.V(util.DebugLevel).Info("added ref to consumer", "consumer_id", consumerIDs[0]) + logger.V(logging.DebugLevel).Info("added ref to consumer", "consumer_id", consumerIDs[0]) } } }