-
Notifications
You must be signed in to change notification settings - Fork 14
Add RUM_INJECTION scenario to test Real User Monitoring SDK injection #5813
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
robertomonteromiguel
merged 14 commits into
main
from
robertomonteromiguel/rum_injection
Dec 12, 2025
Merged
Add RUM_INJECTION scenario to test Real User Monitoring SDK injection #5813
robertomonteromiguel
merged 14 commits into
main
from
robertomonteromiguel/rum_injection
Dec 12, 2025
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Contributor
|
|
cbeauchesne
requested changes
Dec 3, 2025
Co-authored-by: Charles de Beauchesne <charles.debeauchesne@datadoghq.com>
amarziali
previously requested changes
Dec 9, 2025
Contributor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@robertomonteromiguel apparently DataDog/dd-trace-java#10150 is needed to have the test passes.
hennadii-datadog
approved these changes
Dec 11, 2025
amarziali
approved these changes
Dec 11, 2025
Contributor
amarziali
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok for dd-trace-java
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
RUM (Real User Monitoring) auto-injection is a tracer feature that automatically injects the RUM SDK script into HTML responses served by instrumented applications. This allows frontend monitoring to be enabled without requiring manual code changes in the application.
Until now, system-tests had no way to validate this functionality because:
https://docs.datadoghq.com/real_user_monitoring/application_monitoring/browser/setup/server/java/
Related with this draft PR: https://github.com/DataDog/system-tests/pull/5809/files
Changes
New /html endpoint:
Introduces an HTML controller to the Java Spring Boot weblog. This is the first endpoint in system-tests that serves rendered HTML content (via Thymeleaf templates) rather than JSON responses. This pattern can be extended to other weblogs as needed.
New RUM_INJECTION scenario:
A dedicated end-to-end scenario that enables RUM injection via environment variables:
Test validations:
✅ HTML response is well-formed
✅ RUM SDK script (datadoghq-browser-agent.com/datadog-rum-v*) is injected
✅ RUM initialization call (window.DD_RUM.init) is present
The new scenario is not added to the CI yet.
Workflow
🚀 Once your PR is reviewed and the CI green, you can merge it!
🛟 #apm-shared-testing 🛟
Reviewer checklist
[<language>], double-check that only<language>is impacted by the changebuild-XXX-imagelabel is present