Skip to content

Commit

Permalink
Enable quartz instrumentation by default (#2313)
Browse files Browse the repository at this point in the history
  • Loading branch information
trask authored Jun 2, 2022
1 parent 993f6f5 commit d55bd30
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@ public static class Instrumentation {
public LoggingInstrumentation logging = new LoggingInstrumentation();
public MicrometerInstrumentation micrometer = new MicrometerInstrumentation();
public EnabledByDefaultInstrumentation mongo = new EnabledByDefaultInstrumentation();
public EnabledByDefaultInstrumentation quartz = new EnabledByDefaultInstrumentation();
public EnabledByDefaultInstrumentation rabbitmq = new EnabledByDefaultInstrumentation();
public EnabledByDefaultInstrumentation redis = new EnabledByDefaultInstrumentation();
public EnabledByDefaultInstrumentation springScheduling = new EnabledByDefaultInstrumentation();
Expand Down Expand Up @@ -424,6 +425,8 @@ public static class PreviewInstrumentation {
@Deprecated
public DisabledByDefaultInstrumentation jaxws = new DisabledByDefaultInstrumentation();

// this is just here to detect if using this old setting in order to give a helpful message
@Deprecated
public DisabledByDefaultInstrumentation quartz = new DisabledByDefaultInstrumentation();

// this is just here to detect if using this old setting in order to give a helpful message
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,12 @@ public static Configuration create(Path agentJarPath, @Nullable RpConfiguration
+ " and it is now enabled by default,"
+ " so no need to enable it under preview configuration");
}
if (config.preview.instrumentation.quartz.enabled) {
configurationLogger.warn(
"\"quartz\" instrumentation is no longer in preview"
+ " and it is now enabled by default,"
+ " so no need to enable it under preview configuration");
}
if (config.preview.instrumentation.rabbitmq.enabled) {
configurationLogger.warn(
"\"rabbitmq\" instrumentation is no longer in preview"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,9 @@ private static void enableInstrumentations(Configuration config, Map<String, Str
if (config.instrumentation.mongo.enabled) {
properties.put("otel.instrumentation.mongo.enabled", "true");
}
if (config.instrumentation.quartz.enabled) {
properties.put("otel.instrumentation.quartz.enabled", "true");
}
if (config.instrumentation.rabbitmq.enabled) {
properties.put("otel.instrumentation.rabbitmq.enabled", "true");
properties.put("otel.instrumentation.spring-rabbitmq.enabled", "true");
Expand All @@ -260,9 +263,6 @@ private static void enableInstrumentations(Configuration config, Map<String, Str
// note: grizzly instrumentation is off by default upstream
properties.put("otel.instrumentation.grizzly.enabled", "true");
}
if (config.preview.instrumentation.quartz.enabled) {
properties.put("otel.instrumentation.quartz.enabled", "true");
}
if (config.preview.instrumentation.springIntegration.enabled) {
properties.put("otel.instrumentation.spring-integration.enabled", "true");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ enum Feature {
LEGACY_PROPAGATION_ENABLED(18), // legacy propagation is disabled by default
GRIZZLY_ENABLED(19), // preview instrumentation, grizzly is OFF by default in OTEL
STATSBEAT_DISABLED(20), // disable non-essential statsbeat
QUARTZ_DISABLED(21), // preview instrumentation, quartz is ON by default in OTEL
QUARTZ_DISABLED(21),
APACHE_CAMEL_DISABLED(22), // preview instrumentation, apache camel is ON by default in OTEL
AKKA_DISABLED(23), // preview instrumentation, akka is ON by default in OTEL
PROPAGATION_DISABLED(24),
Expand Down

0 comments on commit d55bd30

Please sign in to comment.