diff --git a/dd-trace-api/src/main/java/datadog/trace/api/config/LlmObsConfig.java b/dd-trace-api/src/main/java/datadog/trace/api/config/LlmObsConfig.java index c7ef5a50135..111f8ebc7af 100644 --- a/dd-trace-api/src/main/java/datadog/trace/api/config/LlmObsConfig.java +++ b/dd-trace-api/src/main/java/datadog/trace/api/config/LlmObsConfig.java @@ -6,11 +6,11 @@ */ public final class LlmObsConfig { - public static final String LLM_OBS_ENABLED = "llmobs.enabled"; + public static final String LLMOBS_ENABLED = "llmobs.enabled"; - public static final String LLM_OBS_ML_APP = "llmobs.ml.app"; + public static final String LLMOBS_ML_APP = "llmobs.ml.app"; - public static final String LLM_OBS_AGENTLESS_ENABLED = "llmobs.agentless.enabled"; + public static final String LLMOBS_AGENTLESS_ENABLED = "llmobs.agentless.enabled"; private LlmObsConfig() {} } diff --git a/internal-api/src/main/java/datadog/trace/api/Config.java b/internal-api/src/main/java/datadog/trace/api/Config.java index 8879fc265b6..02b78b68031 100644 --- a/internal-api/src/main/java/datadog/trace/api/Config.java +++ b/internal-api/src/main/java/datadog/trace/api/Config.java @@ -1341,8 +1341,8 @@ PROFILING_DATADOG_PROFILER_ENABLED, isDatadogProfilerSafeInCurrentEnvironment()) configProvider.getString(IAST_SECURITY_CONTROLS_CONFIGURATION, null); llmObsAgentlessEnabled = - configProvider.getBoolean(LLM_OBS_AGENTLESS_ENABLED, DEFAULT_LLM_OBS_AGENTLESS_ENABLED); - llmObsMlApp = configProvider.getString(LLM_OBS_ML_APP); + configProvider.getBoolean(LLMOBS_AGENTLESS_ENABLED, DEFAULT_LLM_OBS_AGENTLESS_ENABLED); + llmObsMlApp = configProvider.getString(LLMOBS_ML_APP); ciVisibilityTraceSanitationEnabled = configProvider.getBoolean(CIVISIBILITY_TRACE_SANITATION_ENABLED, true); diff --git a/internal-api/src/main/java/datadog/trace/api/InstrumenterConfig.java b/internal-api/src/main/java/datadog/trace/api/InstrumenterConfig.java index 1b8457cbae8..2732e02746b 100644 --- a/internal-api/src/main/java/datadog/trace/api/InstrumenterConfig.java +++ b/internal-api/src/main/java/datadog/trace/api/InstrumenterConfig.java @@ -27,7 +27,7 @@ import static datadog.trace.api.config.GeneralConfig.TRACE_TRIAGE; import static datadog.trace.api.config.GeneralConfig.TRIAGE_REPORT_TRIGGER; import static datadog.trace.api.config.IastConfig.IAST_ENABLED; -import static datadog.trace.api.config.LlmObsConfig.LLM_OBS_ENABLED; +import static datadog.trace.api.config.LlmObsConfig.LLMOBS_ENABLED; import static datadog.trace.api.config.ProfilingConfig.PROFILING_DIRECT_ALLOCATION_ENABLED; import static datadog.trace.api.config.ProfilingConfig.PROFILING_DIRECT_ALLOCATION_ENABLED_DEFAULT; import static datadog.trace.api.config.ProfilingConfig.PROFILING_ENABLED; @@ -202,7 +202,7 @@ private InstrumenterConfig() { iastFullyDisabled = iastEnabled != null && !iastEnabled; usmEnabled = configProvider.getBoolean(USM_ENABLED, DEFAULT_USM_ENABLED); telemetryEnabled = configProvider.getBoolean(TELEMETRY_ENABLED, DEFAULT_TELEMETRY_ENABLED); - llmObsEnabled = configProvider.getBoolean(LLM_OBS_ENABLED, DEFAULT_LLM_OBS_ENABLED); + llmObsEnabled = configProvider.getBoolean(LLMOBS_ENABLED, DEFAULT_LLM_OBS_ENABLED); } else { // disable these features in native-image ciVisibilityEnabled = false; diff --git a/internal-api/src/test/groovy/datadog/trace/api/ConfigTest.groovy b/internal-api/src/test/groovy/datadog/trace/api/ConfigTest.groovy index 611d2e996ac..ae07c2d5cd6 100644 --- a/internal-api/src/test/groovy/datadog/trace/api/ConfigTest.groovy +++ b/internal-api/src/test/groovy/datadog/trace/api/ConfigTest.groovy @@ -63,9 +63,9 @@ import static datadog.trace.api.config.JmxFetchConfig.JMX_FETCH_REFRESH_BEANS_PE import static datadog.trace.api.config.JmxFetchConfig.JMX_FETCH_STATSD_HOST import static datadog.trace.api.config.JmxFetchConfig.JMX_FETCH_STATSD_PORT import static datadog.trace.api.config.JmxFetchConfig.JMX_TAGS -import static datadog.trace.api.config.LlmObsConfig.LLM_OBS_AGENTLESS_ENABLED -import static datadog.trace.api.config.LlmObsConfig.LLM_OBS_ML_APP -import static datadog.trace.api.config.LlmObsConfig.LLM_OBS_ENABLED +import static datadog.trace.api.config.LlmObsConfig.LLMOBS_AGENTLESS_ENABLED +import static datadog.trace.api.config.LlmObsConfig.LLMOBS_ML_APP +import static datadog.trace.api.config.LlmObsConfig.LLMOBS_ENABLED import static datadog.trace.api.config.ProfilingConfig.PROFILING_AGENTLESS import static datadog.trace.api.config.ProfilingConfig.PROFILING_API_KEY_FILE_OLD import static datadog.trace.api.config.ProfilingConfig.PROFILING_API_KEY_FILE_VERY_OLD @@ -2217,7 +2217,7 @@ class ConfigTest extends DDSpecification { def "config instantiation should fail if llm obs is enabled via sys prop and ml app is not set"() { setup: Properties properties = new Properties() - properties.setProperty(LLM_OBS_ENABLED, "true") + properties.setProperty(LLMOBS_ENABLED, "true") when: new Config(ConfigProvider.withPropertiesOverride(properties)) @@ -2241,9 +2241,9 @@ class ConfigTest extends DDSpecification { def "config instantiation should NOT fail if llm obs is enabled (agentless disabled) via sys prop and ml app is set"() { setup: Properties properties = new Properties() - properties.setProperty(LLM_OBS_ENABLED, "true") - properties.setProperty(LLM_OBS_AGENTLESS_ENABLED, "false") - properties.setProperty(LLM_OBS_ML_APP, "test-ml-app") + properties.setProperty(LLMOBS_ENABLED, "true") + properties.setProperty(LLMOBS_AGENTLESS_ENABLED, "false") + properties.setProperty(LLMOBS_ML_APP, "test-ml-app") when: def config = new Config(ConfigProvider.withPropertiesOverride(properties)) @@ -2273,9 +2273,9 @@ class ConfigTest extends DDSpecification { def "config instantiation should fail if llm obs is in agentless mode via sys prop and API key is not set"() { setup: Properties properties = new Properties() - properties.setProperty(LLM_OBS_ENABLED, "true") - properties.setProperty(LLM_OBS_AGENTLESS_ENABLED, "true") - properties.setProperty(LLM_OBS_ML_APP, "test-ml-app") + properties.setProperty(LLMOBS_ENABLED, "true") + properties.setProperty(LLMOBS_AGENTLESS_ENABLED, "true") + properties.setProperty(LLMOBS_ML_APP, "test-ml-app") when: new Config(ConfigProvider.withPropertiesOverride(properties)) @@ -2300,9 +2300,9 @@ class ConfigTest extends DDSpecification { def "config instantiation should NOT fail if llm obs is enabled (agentless enabled) and API key & ml app are set via sys prop"() { setup: Properties properties = new Properties() - properties.setProperty(LLM_OBS_ENABLED, "true") - properties.setProperty(LLM_OBS_AGENTLESS_ENABLED, "true") - properties.setProperty(LLM_OBS_ML_APP, "test-ml-app") + properties.setProperty(LLMOBS_ENABLED, "true") + properties.setProperty(LLMOBS_AGENTLESS_ENABLED, "true") + properties.setProperty(LLMOBS_ML_APP, "test-ml-app") properties.setProperty(API_KEY, "123456789") when: