From 49509d8f171c2dfafb54de5a94a02b456522a160 Mon Sep 17 00:00:00 2001 From: "nastassia.dailidava" Date: Tue, 17 Dec 2024 21:05:00 +0100 Subject: [PATCH] added log for empty load assignment --- .../envoycontrol/snapshot/EnvoySnapshotFactory.kt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/snapshot/EnvoySnapshotFactory.kt b/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/snapshot/EnvoySnapshotFactory.kt index 18c1f55d5..a08b1ed20 100644 --- a/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/snapshot/EnvoySnapshotFactory.kt +++ b/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/snapshot/EnvoySnapshotFactory.kt @@ -339,11 +339,11 @@ class EnvoySnapshotFactory( egressRouteSpecification ).also { e -> val list = e.mapNotNull { el -> el.endpointsList.find { x -> x.lbEndpointsList.isEmpty() } } - if (list.isNotEmpty() && - group.proxySettings.outgoing.defaultServiceSettings.routingPolicy.autoServiceTag) { + val rPolicy = group.proxySettings.outgoing.defaultServiceSettings.routingPolicy + if (list.isNotEmpty() && list.none { it.locality.zone.contains("gcp") } && rPolicy.autoServiceTag) { logger.warn( "Some of service ${group.serviceName} dependencies have ClusterLoadAssignment with empty " + - "lbEndpoints: $list" + "lbEndpoints: $list, routingPolicy: $rPolicy, all endpoints: $e" ) } }