/** * The `/signals` and `/errors` routes' `onTick` — one implementation, used by both. * * A supervised external scanner runs in its own Python process, so the only facts the runtime has * about one of its ticks are the ones that arrive over the intake. Both routes already fire once * per tick — `/signals` on every clean tick including a quiet one, `/errors` on every failed one — * so the facts ride the request that tick already makes. No second channel, no extra POST, and a * producer that sends none behaves exactly as it did before. * * What this does with them is hand the run to the SAME process sink the in-process scanner runtime * hands its own finished runs to ({@link ../../telemetry/scanner-tick-feed.js}), which is a no-op * until a client is watching. Nothing here reaches `logger.event` or `appendDomainEvent`: a tick is * a LEVEL, and per-tick records would evict real decision rows from the on-disk ring and the * publisher's bounded buffer. * * ABSENT IS NOT ZERO, end to end. A field the producer did not send is left off the run rather than * defaulted, so the publisher can leave it off the frame and the screen can print "unknown" instead * of a number nobody measured. */ import { type ScannerTickExtras } from "../../telemetry/scanner-tick-feed.js"; import type { IntakeContext } from "./intake-context.js"; import type { IntakeTickFacts } from "./types.js"; /** The producer's facts as the tick feed's extras, with every unreadable field left off. */ export declare function toTickExtras(facts: IntakeTickFacts): ScannerTickExtras; /** * Build the `onTick` both intake routes call. * * Resolves against the SHARED IntakeContext registry, like `onAccepted` and `onScaffoldError`, so * the tick is attributed to the scanner's STABLE name and its runtime's wallet rather than to the * ephemeral scanner_id a relaunch re-mints — which is the key a client joins a tick to its stats * row on. * * `now` is the runtime clock at the POST, used as the run's finish. The producer's own clock is not * used: it is a different machine's wall time, and a frame mixing the two would put ticks in an * order neither machine saw. `startedAt` is derived from the duration the producer measured, which * keeps `ms` the producer's own number while `t` stays on this box's clock. */ export declare function buildScaffoldTickRouter(ctx: IntakeContext, now?: () => number): (scannerId: string, facts: IntakeTickFacts) => void; //# sourceMappingURL=scaffold-tick-router.d.ts.map