diff --git a/instrumentation/internal/internal-class-loader/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/classloader/ClassLoaderInstrumentationModule.java b/instrumentation/internal/internal-class-loader/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/classloader/ClassLoaderInstrumentationModule.java index 24c2103cfc30..b544abcef43e 100644 --- a/instrumentation/internal/internal-class-loader/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/classloader/ClassLoaderInstrumentationModule.java +++ b/instrumentation/internal/internal-class-loader/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/classloader/ClassLoaderInstrumentationModule.java @@ -18,6 +18,12 @@ public ClassLoaderInstrumentationModule() { super("internal-class-loader"); } + @Override + public boolean defaultEnabled() { + // internal instrumentations are always enabled by default + return true; + } + @Override public boolean isHelperClass(String className) { return className.equals("io.opentelemetry.javaagent.tooling.Constants"); diff --git a/instrumentation/internal/internal-eclipse-osgi-3.6/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/osgi/EclipseOsgiInstrumentationModule.java b/instrumentation/internal/internal-eclipse-osgi-3.6/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/osgi/EclipseOsgiInstrumentationModule.java index 806653591bda..f5d7e8cd2291 100644 --- a/instrumentation/internal/internal-eclipse-osgi-3.6/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/osgi/EclipseOsgiInstrumentationModule.java +++ b/instrumentation/internal/internal-eclipse-osgi-3.6/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/osgi/EclipseOsgiInstrumentationModule.java @@ -18,6 +18,12 @@ public EclipseOsgiInstrumentationModule() { super("internal-eclipse-osgi"); } + @Override + public boolean defaultEnabled() { + // internal instrumentations are always enabled by default + return true; + } + @Override public List typeInstrumentations() { return singletonList(new EclipseOsgiInstrumentation()); diff --git a/instrumentation/internal/internal-proxy/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/proxy/ProxyInstrumentationModule.java b/instrumentation/internal/internal-proxy/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/proxy/ProxyInstrumentationModule.java index 6cb26cae0c3d..347496a0a64b 100644 --- a/instrumentation/internal/internal-proxy/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/proxy/ProxyInstrumentationModule.java +++ b/instrumentation/internal/internal-proxy/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/proxy/ProxyInstrumentationModule.java @@ -18,6 +18,12 @@ public ProxyInstrumentationModule() { super("internal-proxy"); } + @Override + public boolean defaultEnabled() { + // internal instrumentations are always enabled by default + return true; + } + @Override public List typeInstrumentations() { return singletonList(new ProxyInstrumentation()); diff --git a/instrumentation/internal/internal-url-class-loader/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/urlclassloader/UrlClassLoaderInstrumentationModule.java b/instrumentation/internal/internal-url-class-loader/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/urlclassloader/UrlClassLoaderInstrumentationModule.java index ee300e582c0c..03f92be72deb 100644 --- a/instrumentation/internal/internal-url-class-loader/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/urlclassloader/UrlClassLoaderInstrumentationModule.java +++ b/instrumentation/internal/internal-url-class-loader/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/internal/urlclassloader/UrlClassLoaderInstrumentationModule.java @@ -18,6 +18,12 @@ public UrlClassLoaderInstrumentationModule() { super("internal-url-class-loader"); } + @Override + public boolean defaultEnabled() { + // internal instrumentations are always enabled by default + return true; + } + @Override public List typeInstrumentations() { return singletonList(new UrlClassLoaderInstrumentation());