Skip to content

Commit

Permalink
Added logs #292
Browse files Browse the repository at this point in the history
  • Loading branch information
nastassia-dailidava committed Sep 14, 2023
1 parent 637b507 commit f03c8f9
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ class EnvoySnapshotFactory(
val removedClusters = previous - current.keys
current + removedClusters
}

false -> current
}
}
Expand Down Expand Up @@ -198,6 +199,7 @@ class EnvoySnapshotFactory(
is ServicesGroup -> {
definedServicesRoutes
}

is AllServicesGroup -> {
val servicesNames = group.proxySettings.outgoing.getServiceDependencies().map { it.service }.toSet()
val allServicesRoutes = globalSnapshot.allServicesNames.subtract(servicesNames).map {
Expand Down Expand Up @@ -226,6 +228,10 @@ class EnvoySnapshotFactory(
val enabledForDependency = globalSnapshot.endpoints[clusterName]?.endpointsList
?.any { e -> trafficSplitting.zoneName == e.locality.zone }
?: false
logger.debug(
"Traffic splitting route spec, enabled: $trafficSplitting, " +
"weights: $weights, enabledForDependency: $enabledForDependency"
)
return if (weights != null && enabledForDependency) {
WeightRouteSpecification(
clusterName,
Expand Down

0 comments on commit f03c8f9

Please sign in to comment.