Datadog
Datadog logoDatadog · Feature trail

Java APM Class Matching Optimization

1 post · Aug 2026

What this trail covers

Datadog's APM Java agent has significantly improved its class-matching performance during startup. This involved optimizing the process of identifying which classes to instrument for observability. The team developed a novel approach by encoding a prefix trie, used for matching class name prefixes, directly as a JVM constant. This allows the trie to be loaded with a single bytecode instruction, eliminating the need for resource lookups and file parsing during the constrained `premain` phase.

All Datadog trails