From f3c7457518bad38a4025e6cfeab3333460b0962c Mon Sep 17 00:00:00 2001 From: "nastassia.dailidava" Date: Tue, 17 Dec 2024 21:07:57 +0100 Subject: [PATCH] added log for empty load assignment --- .../envoycontrol/snapshot/EnvoySnapshotFactory.kt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) 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 a08b1ed20..3f8fb3a7b 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 @@ -340,7 +340,10 @@ class EnvoySnapshotFactory( ).also { e -> val list = e.mapNotNull { el -> el.endpointsList.find { x -> x.lbEndpointsList.isEmpty() } } val rPolicy = group.proxySettings.outgoing.defaultServiceSettings.routingPolicy - if (list.isNotEmpty() && list.none { it.locality.zone.contains("gcp") } && rPolicy.autoServiceTag) { + if (list.isNotEmpty() && + list.none { it.locality.zone.contains(properties.loadBalancing.trafficSplitting.zoneName) } && + rPolicy.autoServiceTag + ) { logger.warn( "Some of service ${group.serviceName} dependencies have ClusterLoadAssignment with empty " + "lbEndpoints: $list, routingPolicy: $rPolicy, all endpoints: $e"