Skip to content

Commit

Permalink
Run class load listener only once (open-telemetry#12565)
Browse files Browse the repository at this point in the history
  • Loading branch information
laurit authored and Alex Kats committed Nov 21, 2024
1 parent 817fe69 commit 14a1eed
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,6 @@ private static void installBytebuddyAgent(
.with(new RedefinitionDiscoveryStrategy())
.with(AgentBuilder.DescriptionStrategy.Default.POOL_ONLY)
.with(AgentTooling.poolStrategy())
.with(new ClassLoadListener())
.with(AgentTooling.transformListener())
.with(AgentTooling.locationStrategy());
if (JavaModule.isSupported()) {
Expand Down Expand Up @@ -172,6 +171,7 @@ private static void installBytebuddyAgent(
agentListener.beforeAgent(autoConfiguredSdk);
}

agentBuilder = agentBuilder.with(new ClassLoadListener());
agentBuilder = configureIgnoredTypes(sdkConfig, extensionClassLoader, agentBuilder);

int numberOfLoadedExtensions = 0;
Expand Down

0 comments on commit 14a1eed

Please sign in to comment.