Skip to content

Commit 0fa8ec5

Browse files
committed
docs(stress-tasks): rename mollifier env vars to TRIGGER_MOLLIFIER_* in fanout examples
The two cherry-picked example payload comments (MOLLIFIER_E2E + MOLLIFIER_SHADOW) referenced the pre-rename `MOLLIFIER_*` env vars. They were authored before phase-2 prefixed everything with TRIGGER_. Bring the examples in line with the actual env-var names operators set today, and expand the E2E example to mention the per-org `mollifierEnabled` flag + the synthesised `mollifier.queued` response so the example accurately describes Phase 2 (live mollify) behaviour rather than the phase-1 dual-write semantics those comments were written against.
1 parent c2d7d60 commit 0fa8ec5

1 file changed

Lines changed: 11 additions & 5 deletions

File tree

references/stress-tasks/src/trigger/fanout.ts

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -89,15 +89,21 @@ async function asyncPool<T>(
8989
* @example Combined contention — fan-out + tags + child work
9090
* { "count": 1000, "concurrency": 250, "childSleepMs": 500, "tags": ["combined"] }
9191
*
92-
* @example Mollifier end-to-end smoke — enough volume to trip the proposed defaults
93-
* (MOLLIFIER_TRIP_THRESHOLD=100 / MOLLIFIER_TRIP_WINDOW_MS=200), but only
94-
* matters once phase 3 wires the buffer write. In phase 1, this still goes
95-
* through the existing engine.trigger() path because the gate is no-op.
92+
* @example Mollifier end-to-end (Phase 2 live) — enough volume to trip the
93+
* default trip thresholds (TRIGGER_MOLLIFIER_TRIP_THRESHOLD=100 /
94+
* TRIGGER_MOLLIFIER_TRIP_WINDOW_MS=200). The webapp must be running
95+
* with TRIGGER_MOLLIFIER_ENABLED=1, TRIGGER_MOLLIFIER_SHADOW_MODE=0,
96+
* and the per-org `mollifierEnabled` flag set on the test org. The
97+
* burst should produce a mix of pass-through triggers (under the
98+
* rate ceiling) and synthesised `mollifier.queued` responses
99+
* (over the ceiling, written to the buffer and replayed by the
100+
* drainer). Observe `mollifier.decisions{outcome="mollify"}` and
101+
* dwell_ms on the resulting runs.
96102
* { "count": 500, "concurrency": 500 }
97103
*
98104
* @example Shadow-mode trip observation — fire a 500-fan-out and watch the webapp logs
99105
* for `mollifier.would_mollify` entries. Requires the webapp running with
100-
* MOLLIFIER_ENABLED=1 MOLLIFIER_SHADOW_MODE=1.
106+
* TRIGGER_MOLLIFIER_ENABLED=1 TRIGGER_MOLLIFIER_SHADOW_MODE=1.
101107
* { "count": 500, "concurrency": 500 }
102108
*/
103109
export const fanOutTriggerTask = task({

0 commit comments

Comments
 (0)