From ca0908182f91de984ba3315978e2d130c34f0eed Mon Sep 17 00:00:00 2001 From: Pierre Tessier Date: Tue, 2 Jan 2024 08:51:41 -0500 Subject: [PATCH] [cart] - fix cartServiceFailure flag (#1313) * fix cartServiceFailure flag Signed-off-by: Pierre Tessier * fix cartServiceFailure flag Signed-off-by: Pierre Tessier --------- Signed-off-by: Pierre Tessier Co-authored-by: Juliano Costa --- CHANGELOG.md | 2 ++ docker-compose.yml | 1 + src/cartservice/src/featureflags/FeatureFlagHelper.cs | 4 ---- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5d3f0ee1af..7ea1151794 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,8 @@ release. * [cartservice] disable config reload ([#1312](https://github.com/open-telemetry/opentelemetry-demo/pull/1312)) +* [cartservice] fixed cartServiceFailure feature flag + ([#1313](https://github.com/open-telemetry/opentelemetry-demo/pull/1313)) * [accountingservice] Update dependencies and semconv * ([#1316](https://github.com/open-telemetry/opentelemetry-demo/pull/1316)) diff --git a/docker-compose.yml b/docker-compose.yml index 600d8db5f6..55aefe0669 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -91,6 +91,7 @@ services: - "${CART_SERVICE_PORT}" environment: - CART_SERVICE_PORT + - FEATURE_FLAG_GRPC_SERVICE_ADDR - REDIS_ADDR - OTEL_EXPORTER_OTLP_ENDPOINT - OTEL_RESOURCE_ATTRIBUTES diff --git a/src/cartservice/src/featureflags/FeatureFlagHelper.cs b/src/cartservice/src/featureflags/FeatureFlagHelper.cs index 7256d8dcb2..ded6659fe5 100644 --- a/src/cartservice/src/featureflags/FeatureFlagHelper.cs +++ b/src/cartservice/src/featureflags/FeatureFlagHelper.cs @@ -30,10 +30,6 @@ public async Task GenerateCartError() { return false; } - if (Random.Next(10) != 1) - { - return false; - } var getFlagRequest = new GetFlagRequest { Name = "cartServiceFailure" }; var getFlagResponse = await _featureFlagServiceClient.GetFlagAsync(getFlagRequest);