Skip to content

Commit 8ffeb29

Browse files
authored
Force early classloading for PublishState (#10273)
1 parent 68c7c2a commit 8ffeb29

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

dd-trace-core/src/main/java/datadog/trace/core/CoreTracer.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -656,6 +656,9 @@ private CoreTracer(
656656
assert taggedHeaders != null;
657657
assert baggageMapping != null;
658658

659+
// preload this enum to avoid triggering classloading on the hot path
660+
TraceCollector.PublishState.values();
661+
659662
if (reportInTracerFlare) {
660663
TracerFlare.addReporter(this);
661664
}

0 commit comments

Comments
 (0)