Skip to content

Commit eea5803

Browse files
authored
Merge pull request #1420 from microsoft/trask/fix-disabling
Fix disabling of dependencies
2 parents e3cb3dc + fad6c09 commit eea5803

File tree

1 file changed

+12
-11
lines changed

1 file changed

+12
-11
lines changed

agent/agent-tooling/src/main/java/com/microsoft/applicationinsights/agent/internal/BeforeAgentInstaller.java

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -121,32 +121,33 @@ private static void start(Instrumentation instrumentation) throws Exception {
121121
properties.put("experimental.log.capture.threshold", getLoggingFrameworksThreshold(config, "INFO"));
122122
int reportingIntervalSeconds = getMicrometerReportingIntervalSeconds(config, 60);
123123
properties.put("micrometer.step.millis", Long.toString(SECONDS.toMillis(reportingIntervalSeconds)));
124+
// TODO need some kind of test for these configuration properties
124125
if (!isInstrumentationEnabled(config, "micrometer")) {
125-
properties.put("ota.integration.micrometer.enabled", "false");
126+
properties.put("otel.instrumentation.micrometer.enabled", "false");
126127
}
127128
if (!isInstrumentationEnabled(config, "jdbc")) {
128-
properties.put("ota.integration.jdbc.enabled", "false");
129+
properties.put("otel.instrumentation.jdbc.enabled", "false");
129130
}
130131
if (!isInstrumentationEnabled(config, "logging")) {
131-
properties.put("ota.integration.log4j.enabled", "false");
132-
properties.put("ota.integration.java-util-logging.enabled", "false");
133-
properties.put("ota.integration.logback.enabled", "false");
132+
properties.put("otel.instrumentation.log4j.enabled", "false");
133+
properties.put("otel.instrumentation.java-util-logging.enabled", "false");
134+
properties.put("otel.instrumentation.logback.enabled", "false");
134135
}
135136
if (!isInstrumentationEnabled(config, "redis")) {
136-
properties.put("ota.integration.jedis.enabled", "false");
137-
properties.put("ota.integration.lettuce.enabled", "false");
137+
properties.put("otel.instrumentation.jedis.enabled", "false");
138+
properties.put("otel.instrumentation.lettuce.enabled", "false");
138139
}
139140
if (!isInstrumentationEnabled(config, "kafka")) {
140-
properties.put("ota.integration.kafka.enabled", "false");
141+
properties.put("otel.instrumentation.kafka.enabled", "false");
141142
}
142143
if (!isInstrumentationEnabled(config, "mongo")) {
143-
properties.put("ota.integration.mongo.enabled", "false");
144+
properties.put("otel.instrumentation.mongo.enabled", "false");
144145
}
145146
if (!isInstrumentationEnabled(config, "cassandra")) {
146-
properties.put("ota.integration.cassandra.enabled", "false");
147+
properties.put("otel.instrumentation.cassandra.enabled", "false");
147148
}
148149
if (!config.preview.openTelemetryApiSupport) {
149-
properties.put("ota.integration.opentelemetry-api.enabled", "false");
150+
properties.put("otel.instrumentation.opentelemetry-api.enabled", "false");
150151
}
151152
Config.internalInitializeConfig(Config.create(properties));
152153
if (Config.get().getListProperty("additional.bootstrap.package.prefixes").isEmpty()) {

0 commit comments

Comments
 (0)