Fix sampling for custom instrumentation#2513
Conversation
c238ba1 to
401423d
Compare
401423d to
7b6f48d
Compare
2c6e355 to
7b6f48d
Compare
| @@ -0,0 +1,3 @@ | |||
| This is a copy of the upstream methods instrumentation module, but changed to emit SERVER spans | |||
There was a problem hiding this comment.
can we add this note to MethodSingletons class? it used SpanKindExtractor.alwaysServer(). and then delete this readme?
| // Licensed under the MIT License. | ||
|
|
||
| package io.opentelemetry.javaagent.instrumentation.micrometer; | ||
| package io.opentelemetry.javaagent.instrumentation.micrometer.ai; |
There was a problem hiding this comment.
upstream adds a new package for app insights specifically?
There was a problem hiding this comment.
no, this is to avoid conflicting with upstream's package name (which already uses io.opentelemetry.javaagent.instrumentation.micrometer)
| import net.bytebuddy.implementation.bytecode.assign.Assigner; | ||
| import net.bytebuddy.matcher.ElementMatcher; | ||
|
|
||
| public class MethodInstrumentation implements TypeInstrumentation { |
There was a problem hiding this comment.
can we make a note that this is a temporary solution and long-term solution upstream might be feasible in the near future?
There was a problem hiding this comment.
is this identical to upstream methodInstrumentation?
There was a problem hiding this comment.
I have created a work item for long-term solution
| properties.put("otel.instrumentation.log4j-context-data.enabled", "true"); | ||
| properties.put("otel.instrumentation.logback-mdc.enabled", "true"); | ||
| properties.put("otel.instrumentation.methods.enabled", "true"); | ||
| properties.put("otel.instrumentation.ai-methods.enabled", "true"); |
There was a problem hiding this comment.
…om-instrumentation
No description provided.