Minor cleanup of Tracer declarations
MODIFY
instrumentation/aws-java-sdk-1.11.0/src/main/java/io/opentelemetry/auto/instrumentation/aws/v0/TracingRequestHandler.java
instrumentation/aws-java-sdk-1.11.0/src/main/java/io/opentelemetry/auto/instrumentation/aws/v0/TracingRequestHandler.java
@@ -14,7 +14,8 @@ import io.opentelemetry.trace.Tracer;
/** Tracing Request Handler */
public class TracingRequestHandler extends RequestHandler2 {
- public static final Tracer TRACER = OpenTelemetry.getTracerFactory().get("io.opentelemetry.auto");
+ private static final Tracer TRACER =
+ OpenTelemetry.getTracerFactory().get("io.opentelemetry.auto");
private final AwsSdkClientDecorator decorate;

MODIFY
instrumentation/ratpack-1.4/src/main/java/io/opentelemetry/auto/instrumentation/ratpack/ContinuationInstrumentation.java
instrumentation/ratpack-1.4/src/main/java/io/opentelemetry/auto/instrumentation/ratpack/ContinuationInstrumentation.java
@@ -29,7 +29,7 @@ public final class ContinuationInstrumentation extends Instrumenter.Default {
@Override
public String[] helperClassNames() {
- return new String[] {packageName + ".BlockWrapper", packageName + ".TracerHolder"};
+ return new String[] {packageName + ".BlockWrapper"};
}
@Override

MODIFY
instrumentation/ratpack-1.4/src/main/java/io/opentelemetry/auto/instrumentation/ratpack/DefaultExecutionInstrumentation.java
instrumentation/ratpack-1.4/src/main/java/io/opentelemetry/auto/instrumentation/ratpack/DefaultExecutionInstrumentation.java
@@ -30,7 +30,7 @@ public final class DefaultExecutionInstrumentation extends Instrumenter.Default
@Override
public String[] helperClassNames() {
- return new String[] {packageName + ".ActionWrapper", packageName + ".TracerHolder"};
+ return new String[] {packageName + ".ActionWrapper"};
}
@Override

DELETE
instrumentation/ratpack-1.4/src/main/java/io/opentelemetry/auto/instrumentation/ratpack/TracerHolder.java
-package io.opentelemetry.auto.instrumentation.ratpack;
-
-import io.opentelemetry.OpenTelemetry;
-import io.opentelemetry.trace.Tracer;
-
-public class TracerHolder {
- public static final Tracer TRACER = OpenTelemetry.getTracerFactory().get("io.opentelemetry.auto");
-}

MODIFY
instrumentation/ratpack-1.4/src/main/java8/io/opentelemetry/auto/instrumentation/ratpack/ActionWrapper.java
instrumentation/ratpack-1.4/src/main/java8/io/opentelemetry/auto/instrumentation/ratpack/ActionWrapper.java
@@ -9,7 +9,8 @@ import ratpack.func.Action;
@Slf4j
public class ActionWrapper<T> implements Action<T> {
- public static final Tracer TRACER = OpenTelemetry.getTracerFactory().get("io.opentelemetry.auto");
+ private static final Tracer TRACER =
+ OpenTelemetry.getTracerFactory().get("io.opentelemetry.auto");
private final Action<T> delegate;
private final Span span;

MODIFY
instrumentation/ratpack-1.4/src/main/java8/io/opentelemetry/auto/instrumentation/ratpack/BlockWrapper.java
instrumentation/ratpack-1.4/src/main/java8/io/opentelemetry/auto/instrumentation/ratpack/BlockWrapper.java
@@ -9,7 +9,8 @@ import ratpack.func.Block;
@Slf4j
public class BlockWrapper implements Block {
- public static final Tracer TRACER = OpenTelemetry.getTracerFactory().get("io.opentelemetry.auto");
+ private static final Tracer TRACER =
+ OpenTelemetry.getTracerFactory().get("io.opentelemetry.auto");
private final Block delegate;
private final Span span;

Minor cleanup of Tracer declarations (#125)