You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs(rum): record the dead-bundle case, split blocked from throws
blocked (main.js never arrives), n=12: the agent loaded 12/12 and a Grail beacon
went out 12/12, so RUM was watching; the failed URL reached the beacon 0/12. An
earlier n=4 could not be told apart from sampling, but twelve consecutive
unmonitored sessions is a 0.8% event under costAndTrafficControl 33. Real gap,
and not closeable from our side -- anything we ship to detect it rides in the
bundle that did not arrive.
throws (main.js arrives and throws at module-eval), n=8: the browser reported
Script error. to the page 8/8, it reached RUM 3/8, and was legible 0/8.
Detectable but never diagnosable. The 3 reporting sessions are exactly the 3 with
a ~4890B Classic payload against ~4465B silent -- a ~430B delta that is the error
itself, and 3/8 matches the 33% sampling rate. So the error is captured every
time and transmitted about a third of the time.
This is the realistic code-defect case: a syntax error fails the build and never
ships, but a runtime error during module-eval compiles fine.
Records four mitigation options without implementing any. Only an inline boot
watchdog would cover the blocked case, since being inline and same-origin its
message escapes cross-origin redaction; it would need a mount signal valid for
every react-scripts consumer, and would still be subject to sampling.
Adds a Retrieving the harnesses section pointing at tag
rum-harness-archive-2026-08-17, since the docs cite measurements whose code is
no longer carried on this branch.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: packages/react-scripts/tools/dynatrace/RUM_ERROR_PROBE_SPEC.md
+79-9Lines changed: 79 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -329,17 +329,69 @@ Two notes for whoever picks this up:
329
329
Before shipping it: confirm every asset host in every environment sends `ACAO`, not just
330
330
`edge.fscdn.org` on int, and roll it to int alone first.
331
331
332
-
### Unresolved: blocking `main.js` produces nothing at all
332
+
---
333
+
334
+
## Answered: when the app never starts
335
+
336
+
The two ways this happens have different answers, so
337
+
[beacon-harness/dead-bundle.mjs](https://github.com/fs-webdev/create-react-app/blob/rum-harness-archive-2026-08-17/packages/react-scripts/tools/dynatrace/beacon-harness/dead-bundle.mjs) measures them separately.
338
+
339
+
### `blocked` — main.js never arrives
340
+
341
+
Result on int, **n=12**: the agent loaded in 12/12 and a Grail beacon went out in 12/12, so RUM
342
+
was demonstrably watching. The failed `main.js` URL reached the beacon in **0/12**.
343
+
344
+
The earlier n=4 could not distinguish this from sampling; n=12 can — under
345
+
`costAndTrafficControl: 33`, twelve consecutive unmonitored sessions is a 0.8% event. **This is a
346
+
real gap, and it is not closeable from our side.** Anything we might ship to detect it travels in
347
+
the bundle that did not arrive. Treat it as a known blind spot and detect it elsewhere: synthetic
348
+
monitoring, or a drop in server-side API traffic.
349
+
350
+
### `throws` — main.js arrives and throws while evaluating
351
+
352
+
The realistic code-defect case. A syntax error fails the build and never ships, but a runtime
353
+
error during module-eval compiles cleanly — a missing browser API, a bad assumption about a
354
+
global, anything that works in Chrome and dies in Safari. Result on int, n=8, with the injected
355
+
throw confirmed to have evaluated in 8/8:
356
+
357
+
|||
358
+
| --- | --- |
359
+
| Browser reported `Script error.` to the page |**8/8**|
360
+
| That error reached RUM |**3/8**|
361
+
| ...with a legible message |**0/8**|
362
+
363
+
So the failure is **detectable but never diagnosable**. Two separate limits stack:
333
364
334
-
Mode `early` blocks the main bundle instead of a lazy chunk. Result (n=4): **no error, no failed
335
-
URL, nothing** — including in the 2 of 4 runs where the agent was already live when the request
336
-
failed. That is not what the chunk result predicts.
365
+
**Sampling.** The 3 sessions that reported are exactly the 3 with a ~4890-byte Classic payload,
366
+
against ~4465 or ~1470 for the silent ones — a consistent ~430-byte delta that is the error
367
+
itself. 3/8 ≈ 37.5% matches `costAndTrafficControl: 33`. The error is captured every time and
368
+
*transmitted* about a third of the time. For an outage affecting many patrons that is ample; for
369
+
a defect confined to one browser version on low traffic, it may never surface.
337
370
338
-
Not yet explained, and the sample is too small to lean on. Candidates: the session was a
339
-
`costAndTrafficControl` stub (~1 in 3 are monitored, so 0/4 is unremarkable); or a page whose
340
-
bundle never loads generates too little activity for the agent to flush a full beacon — it sent
341
-
only 2. Worth an n=15 run before drawing anything from it. **If it holds, it matters**: it would
342
-
mean the hardest failure to detect is the one where the app does not start at all.
371
+
**Opacity.** Every one is `"Script error."` with no message, file or line — the cross-origin
372
+
redaction above. You learn the application is broken, not why.
373
+
374
+
### What could be done, if it becomes worth doing
375
+
376
+
Nothing here is currently implemented; recording the options while the measurements are fresh.
0 commit comments