From 8049a04fb922fe9ad0f039c90794757499a0db5a Mon Sep 17 00:00:00 2001 From: Steven Bouwkamp Date: Wed, 23 Oct 2024 11:32:44 -0400 Subject: [PATCH] Attempt to access the configuration key correctly --- .../tracing/contrib/active_support/cache/events/cache.rb | 2 +- .../tracing/contrib/active_support/cache/instrumentation.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/datadog/tracing/contrib/active_support/cache/events/cache.rb b/lib/datadog/tracing/contrib/active_support/cache/events/cache.rb index af9cc664137..1a4f6fe2d97 100644 --- a/lib/datadog/tracing/contrib/active_support/cache/events/cache.rb +++ b/lib/datadog/tracing/contrib/active_support/cache/events/cache.rb @@ -81,7 +81,7 @@ def on_start(span, event, _id, payload) span.set_tag('EVENT', event) - set_cache_key(span, key, mapping[:multi_key]) if datadog_configuration[:cache_key_enabled] + set_cache_key(span, key, mapping[:multi_key]) if datadog_configuration[:active_support][:cache_key_enabled] rescue StandardError => e Datadog.logger.error(e.message) Datadog::Core::Telemetry::Logger.report(e) diff --git a/lib/datadog/tracing/contrib/active_support/cache/instrumentation.rb b/lib/datadog/tracing/contrib/active_support/cache/instrumentation.rb index d55bffd899d..9769b5e3364 100644 --- a/lib/datadog/tracing/contrib/active_support/cache/instrumentation.rb +++ b/lib/datadog/tracing/contrib/active_support/cache/instrumentation.rb @@ -59,7 +59,7 @@ def trace(action, store, key: nil, multi_key: nil) span.set_tag(Ext::TAG_CACHE_BACKEND, store) if store - set_cache_key(span, key, multi_key) if datadog_configuration[:cache_key_enabled] + set_cache_key(span, key, multi_key) if datadog_configuration[:active_support][:cache_key_enabled] yield end