Repository navigation
Enable opt-in frontend health telemetry in released images - #117
Merged
Merged
Conversation
This was referenced Nov 15, 2026
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
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.
Released images currently compile out the RUM integration, leaving existing cache and polling health events unavailable through deployment configuration. Add validated public runtime RUM settings with collection disabled by default, retain Vite development fallbacks, use the package build version and deployment environment, and emit a startup event after SDK initialization.
Deployment contract: RUM_ENABLED=false, RUM_ENDPOINT=/api/v1/frontend/telemetry, RUM_APP_NAME=rush-ui, existing RUSH_ENVIRONMENT. Endpoints must be same-origin paths. No browser credential setting is introduced; the existing privacy scrubber remains in place.
Validation: 18 focused RUM configuration/privacy tests; seven valid/invalid entrypoint rendering cases; full production build and typecheck. Helm wiring is a separate follow-up. Independent main-based PR.
Combined validation: all six frontend health PRs merge together without conflicts. The integrated suite passes 646 tests in 107 files and the production build/typecheck. A production-bundle Chrome smoke with mocked ingestion verified runtime opt-in, actual package version/environment, API/body events, failed lazy-route navigation, investigation completion/malformed-event counts and browser offline/recovery duration. Eleven custom event types arrived through the SDK and production privacy scrubber without query text or user identifiers in their attributes.
Authenticated collection prerequisite: the default is the dedicated session-authenticated POST /api/v1/frontend/telemetry endpoint, implemented in query-api #100, which must merge and deploy before enabling this collector. Generic /api/v1/rum/ingest intentionally rejects browser session credentials and is not the self-health default. Cookies are retained; no embedded ingest key or credential-isolation bypass is introduced. The browser fixture verifies the default path and cookie transport; real handler authorization/payload retention validation is coordinated with the API PR.
Backend acceptance verification: query-api #100 passed real-cookie JSON and text/plain beacon requests against isolated ClickHouse, including viewer-role use, tenant binding and RUM disable gates. Forged/revoked cookies and hostile/missing Origin are denied; generic ingest remains session-denied. Browser-captured event/attribute fixtures are retained by the real Rust sanitizer. Custom app names are stored in the reserved rush-ui: namespace; build version/environment remain intact.