Skip to content

Commit

Permalink
Fix disabling of dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
trask committed Dec 22, 2020
1 parent e3cb3dc commit f6cd925
Showing 1 changed file with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -122,31 +122,31 @@ private static void start(Instrumentation instrumentation) throws Exception {
int reportingIntervalSeconds = getMicrometerReportingIntervalSeconds(config, 60);
properties.put("micrometer.step.millis", Long.toString(SECONDS.toMillis(reportingIntervalSeconds)));
if (!isInstrumentationEnabled(config, "micrometer")) {
properties.put("ota.integration.micrometer.enabled", "false");
properties.put("otel.instrumentation.micrometer.enabled", "false");
}
if (!isInstrumentationEnabled(config, "jdbc")) {
properties.put("ota.integration.jdbc.enabled", "false");
properties.put("otel.instrumentation.jdbc.enabled", "false");
}
if (!isInstrumentationEnabled(config, "logging")) {
properties.put("ota.integration.log4j.enabled", "false");
properties.put("ota.integration.java-util-logging.enabled", "false");
properties.put("ota.integration.logback.enabled", "false");
properties.put("otel.instrumentation.log4j.enabled", "false");
properties.put("otel.instrumentation.java-util-logging.enabled", "false");
properties.put("otel.instrumentation.logback.enabled", "false");
}
if (!isInstrumentationEnabled(config, "redis")) {
properties.put("ota.integration.jedis.enabled", "false");
properties.put("ota.integration.lettuce.enabled", "false");
properties.put("otel.instrumentation.jedis.enabled", "false");
properties.put("otel.instrumentation.lettuce.enabled", "false");
}
if (!isInstrumentationEnabled(config, "kafka")) {
properties.put("ota.integration.kafka.enabled", "false");
properties.put("otel.instrumentation.kafka.enabled", "false");
}
if (!isInstrumentationEnabled(config, "mongo")) {
properties.put("ota.integration.mongo.enabled", "false");
properties.put("otel.instrumentation.mongo.enabled", "false");
}
if (!isInstrumentationEnabled(config, "cassandra")) {
properties.put("ota.integration.cassandra.enabled", "false");
properties.put("otel.instrumentation.cassandra.enabled", "false");
}
if (!config.preview.openTelemetryApiSupport) {
properties.put("ota.integration.opentelemetry-api.enabled", "false");
properties.put("otel.instrumentation.opentelemetry-api.enabled", "false");
}
Config.internalInitializeConfig(Config.create(properties));
if (Config.get().getListProperty("additional.bootstrap.package.prefixes").isEmpty()) {
Expand Down

0 comments on commit f6cd925

Please sign in to comment.