From 2f3e2b924280733541e5cdab5b3086dc9e7f36b3 Mon Sep 17 00:00:00 2001 From: "mateusz.bartkowiak" Date: Tue, 12 Dec 2023 11:22:58 +0100 Subject: [PATCH 1/2] shouldAuditGlobalSnapshot property --- .../allegro/tech/servicemesh/envoycontrol/ControlPlane.kt | 6 +++++- .../servicemesh/envoycontrol/snapshot/SnapshotProperties.kt | 1 + 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/ControlPlane.kt b/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/ControlPlane.kt index bc02ee3c5..c7fe1136c 100644 --- a/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/ControlPlane.kt +++ b/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/ControlPlane.kt @@ -337,7 +337,11 @@ class ControlPlane private constructor( } fun withSnapshotChangeAuditor(snapshotChangeAuditor: SnapshotChangeAuditor): ControlPlaneBuilder { - this.snapshotChangeAuditor = snapshotChangeAuditor + if (properties.envoy.snapshot.shouldAuditGlobalSnapshot) { + this.snapshotChangeAuditor = snapshotChangeAuditor + } else { + this.snapshotChangeAuditor = NoopSnapshotChangeAuditor + } return this } diff --git a/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/snapshot/SnapshotProperties.kt b/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/snapshot/SnapshotProperties.kt index 9590a1801..ed1bb20af 100644 --- a/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/snapshot/SnapshotProperties.kt +++ b/envoy-control-core/src/main/kotlin/pl/allegro/tech/servicemesh/envoycontrol/snapshot/SnapshotProperties.kt @@ -36,6 +36,7 @@ class SnapshotProperties { var deltaXdsEnabled = false var retryPolicy = RetryPolicyProperties() var tcpDumpsEnabled: Boolean = true + var shouldAuditGlobalSnapshot: Boolean = true } class MetricsProperties { From d9ac0e8c5286e40fdfa073d8b88d3bc07f2ffa27 Mon Sep 17 00:00:00 2001 From: "mateusz.bartkowiak" Date: Tue, 12 Dec 2023 11:26:49 +0100 Subject: [PATCH 2/2] shouldAuditGlobalSnapshot property --- CHANGELOG.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index f3bf18332..001c56f09 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,11 @@ Lists all changes with user impact. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). +## [0.20.4] + +### Changed +- Fix `shouldAuditGlobalSnapshot` property + ## [0.20.3] ### Changed