fix(telemetry): rename record waterfall

This commit is contained in:
Tianyi Cui
2026-07-27 21:30:28 +08:00
parent 4182dbdc86
commit 0af16387ae
21 changed files with 57 additions and 55 deletions

View File

@@ -1,7 +1,7 @@
# Test-only composition: session-telemetry-otel through the real Loader/app
# path, exporting to the mock OTLP collector the driver starts (url via env).
# The redact-rule entry models a deployment mounting its own scrub rule on the
# telemetry/redact waterfall — the seam itself ships no rules.
# telemetry/record waterfall — the seam itself ships no rules.
- id: cli-mock-llm
name: './cli-mock-llm.ts'

View File

@@ -3,7 +3,7 @@ import type { Context } from 'cordis'
/**
* Deployment-style redaction rule for the telemetry e2e: scrubs the fixture
* credential from body strings, exactly as a real deployment would mount its
* own rules on the `telemetry/redact` waterfall.
* own rules on the `telemetry/record` waterfall.
*/
const SECRET = /sk-e2efixture[0-9]+/g
@@ -22,7 +22,7 @@ export const name = 'telemetry-redact-rule'
/** Mount the fixture scrub rule onto the redact waterfall. */
export function apply(ctx: Context): void {
ctx.on('telemetry/redact', (_record, next) => {
ctx.on('telemetry/record', (_record, next) => {
const record = next()
return { ...record, body: scrub(record.body) }
})