Manually inject AWS SDK helpers since they are refrenced from resource file, not code.
MODIFY
instrumentation/aws-sdk/aws-sdk-2.2/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/awssdk/v2_2/AwsSdkInstrumentationModule.java
instrumentation/aws-sdk/aws-sdk-2.2/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/awssdk/v2_2/AwsSdkInstrumentationModule.java
@@ -20,6 +20,20 @@ public class AwsSdkInstrumentationModule extends InstrumentationModule {
super("aws-sdk", "aws-sdk-2.2");
}
+ @Override
+ public String[] additionalHelperClassNames() {
+ return new String[] {
+ "io.opentelemetry.javaagent.instrumentation.awssdk.v2_2.TracingExecutionInterceptor",
+ "io.opentelemetry.instrumentation.awssdk.v2_2.AwsSdk",
+ "io.opentelemetry.instrumentation.awssdk.v2_2.AwsSdkHttpClientTracer",
+ "io.opentelemetry.instrumentation.awssdk.v2_2.AwsSdkInjectAdapter",
+ "io.opentelemetry.instrumentation.awssdk.v2_2.RequestType",
+ "io.opentelemetry.instrumentation.awssdk.v2_2.SdkRequestDecorator",
+ "io.opentelemetry.instrumentation.awssdk.v2_2.DbRequestDecorator",
+ "io.opentelemetry.instrumentation.awssdk.v2_2.TracingExecutionInterceptor"
+ };
+ }
+
/**
* Injects resource file with reference to our {@link TracingExecutionInterceptor} to allow SDK's
* service loading mechanism to pick it up.

MODIFY
instrumentation/aws-sdk/aws-sdk-2.2/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/awssdk/v2_2/TracingExecutionInterceptor.java
instrumentation/aws-sdk/aws-sdk-2.2/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/awssdk/v2_2/TracingExecutionInterceptor.java
@@ -45,10 +45,6 @@ public class TracingExecutionInterceptor implements ExecutionInterceptor {
delegate = AwsSdk.newInterceptor();
}
- public static void muzzleCheck() {
- // Noop
- }
-
@Override
public void beforeExecution(BeforeExecution context, ExecutionAttributes executionAttributes) {
delegate.beforeExecution(context, executionAttributes);

Manually inject AWS SDK helpers since they are refrenced from resource file, not code. (#1876)