-
Notifications
You must be signed in to change notification settings - Fork 199
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Quartz and Apache Camel preview instrumentations #1899
Changes from 3 commits
c6afa57
fcf5a36
ca544bc
b224509
06f30e8
a1101f9
2584919
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -71,11 +71,17 @@ static Config getConfig(Configuration config) { | |
if (!config.instrumentation.springScheduling.enabled) { | ||
properties.put("otel.instrumentation.spring-scheduling.enabled", "false"); | ||
} | ||
if (!config.preview.instrumentation.apacheCamel.enabled) { | ||
properties.put("otel.instrumentation.apache-camel.enabled", "false"); | ||
} | ||
if (config.preview.instrumentation.grizzly.enabled) { | ||
// grizzly instrumentation is off by default | ||
// TODO (trask) investigate if grizzly instrumentation can be enabled upstream by default now | ||
properties.put("otel.instrumentation.grizzly.enabled", "true"); | ||
} | ||
if (!config.preview.instrumentation.quartz.enabled) { | ||
properties.put("otel.instrumentation.quartz.enabled", "false"); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. same here. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. same here |
||
} | ||
if (!config.preview.instrumentation.springIntegration.enabled) { | ||
properties.put("otel.instrumentation.spring-integration.enabled", "false"); | ||
} | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -49,7 +49,9 @@ enum Feature { | |
SPRING_INTEGRATION_DISABLED(19), | ||
LEGACY_PROPAGATION_DISABLED(20), | ||
GRIZZLY_DISABLED(21), // preview instrumentation | ||
STATSBEAT_DISABLED(22); // disable non-essential statsbeat | ||
STATSBEAT_DISABLED(22), // disable non-essential statsbeat | ||
QUARTZ_DISABLED(23), // preview instrumentation | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. QUARTZ_ENABLED? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. just following existing convention, do u want to change it for grizzle and spring integration also? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. grizzly is disabled by default though. which convention are you referring to? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. yup, GRIZZLY_ENABLED makes more sense in this case. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. all preview instrumentations are disabled by default There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. except statsbeat is on by default. check overrideconfig, grizzly check enabled and then set it because its default is false. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can I suggest that you push commit to this PR to update Statsbeat tracking to the way you would like it to be? |
||
APACHE_CAMEL_DISABLED(24); // preview instrumentation | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. APACHE_CAMEL_ENABLED? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. just following convention, do you want to change it for existing too? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. yes, please. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. or i can clean up after your pr, just fix yours for now. i think other instrumentations were moved recently from instrumentation to preview. |
||
|
||
private static final Map<String, Feature> javaVendorFeatureMap; | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -129,9 +129,15 @@ void trackConfigurationOptions(Configuration config) { | |
} | ||
|
||
// preview instrumentation | ||
if (!config.preview.instrumentation.apacheCamel.enabled) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. check enabled not negation? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. again, just following convention, let me know if you want to change it for existing too There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. feature tracking is based on default value.. if it's off by default, we track on; on by default, we track off.. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I agree what you suggest would be better, but that's not how current features work, do you want me to change the existing convention? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. i think it's because moving config from instrumentation to preview make it confusing.. under instrumentation, it's on by default.. now preview default is off.. once it moves to preview, we change the default value.. that's why feature needs to be updated as well to reflect this change. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @heyams please send a commit to this PR to update statsbeat the way you want it |
||
featureList.add(Feature.APACHE_CAMEL_DISABLED); | ||
} | ||
if (!config.preview.instrumentation.grizzly.enabled) { | ||
featureList.add(Feature.GRIZZLY_DISABLED); | ||
} | ||
if (!config.preview.instrumentation.quartz.enabled) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. same here. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. same here |
||
featureList.add(Feature.QUARTZ_DISABLED); | ||
} | ||
if (!config.preview.instrumentation.springIntegration.enabled) { | ||
featureList.add(Feature.SPRING_INTEGRATION_DISABLED); | ||
} | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -39,6 +39,7 @@ dependencies { | |
exclude("ch.qos.logback", "logback-core") | ||
} | ||
|
||
implementation("io.opentelemetry.javaagent.instrumentation:opentelemetry-javaagent-apache-camel-2.20:$otelInstrumentationAlphaVersion") | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. do we need to add this to the instrumentation list? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. isn't that what this does?
|
||
implementation("io.opentelemetry.javaagent.instrumentation:opentelemetry-javaagent-apache-httpasyncclient-4.1:$otelInstrumentationAlphaVersion") | ||
implementation("io.opentelemetry.javaagent.instrumentation:opentelemetry-javaagent-apache-httpclient-2.0:$otelInstrumentationAlphaVersion") | ||
implementation("io.opentelemetry.javaagent.instrumentation:opentelemetry-javaagent-apache-httpclient-4.0:$otelInstrumentationAlphaVersion") | ||
|
@@ -106,6 +107,7 @@ dependencies { | |
implementation("io.opentelemetry.javaagent.instrumentation:opentelemetry-javaagent-opentelemetry-annotations-1.0:$otelInstrumentationAlphaVersion") | ||
implementation("io.opentelemetry.javaagent.instrumentation:opentelemetry-javaagent-opentelemetry-api-1.0:$otelInstrumentationAlphaVersion") | ||
implementation("io.opentelemetry.javaagent.instrumentation:opentelemetry-javaagent-opentelemetry-api-metrics-1.0:$otelInstrumentationAlphaVersion") | ||
implementation("io.opentelemetry.javaagent.instrumentation:opentelemetry-javaagent-quartz-2.0:$otelInstrumentationAlphaVersion") | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. instrumentation list? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. isn't that what this does?
|
||
implementation("io.opentelemetry.javaagent.instrumentation:opentelemetry-javaagent-rabbitmq-2.7:$otelInstrumentationAlphaVersion") | ||
implementation("io.opentelemetry.javaagent.instrumentation:opentelemetry-javaagent-reactor-3.1:$otelInstrumentationAlphaVersion") | ||
implementation("io.opentelemetry.javaagent.instrumentation:opentelemetry-javaagent-reactor-netty-0.9:$otelInstrumentationAlphaVersion") | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is off by default.. should check for enabled and then set it to true?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
otel.instrumentation.apache-camel.enabled
is true by defaultThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DisabledByDefaultInstrumentation is disabled by default. If it's true, this object doesn't seem right.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not following, can you make a specific suggestion?