Join the Preview!
RUM Auto-Instrumentation through Java servlet-based web servers is in Preview.
Request AccessOverview
RUM Auto-Instrumentation automatically adds RUM monitoring to your web application server, so you can start collecting RUM data by editing a configuration file instead of having to modify your frontend code directly. However, if you want to track specific user actions (custom actions) or add custom event details (event attributes), you still need to add some code to your application.
How it works
The Java SDK works by monitoring your servlet API (which handles web requests and responses), automatically checking each HTTP response your server sends. When it detects an HTML response, it looks for the <head>
section and automatically adds the RUM JavaScript code there. The rest of your HTML content remains unchanged. This approach adds minimal overhead, so it works well even with streaming responses (where content is sent in real-time).
Prerequisites
Server requirements
- Java web application server with Servlet API 3.0 or higher support:
- Jetty 7+
- Tomcat 7+
- GlassFish 3+ / Payara 4.1+
- JBoss AS 6+ / Wildfly 8+
- Undertow 1+
- WebLogic 12+
- WebSphere AS 8+ / Open Liberty 17+
SDK requirements
- Java SDK installed using either:
Datadog configuration
- RUM application created in Datadog
- Configuration values ready:
clientToken
applicationId
remoteConfigurationId
Configuration
To get access to configuration steps for this feature, join the preview program.
Further reading
Additional helpful documentation, links, and articles: