/** * The Receiver's unit for a cap: the bytes its rate regulator counts. * * The regulator charges each event `utf8Size()` of the record as it arrives * from the forwarder: the compact JSON with its metadata (the `kubernetes` * map, the stream, the forwarder's own fields), not the log payload alone. * A multi-line event is one record, its continuation lines joined into the * head record's payload. Measured on the containment demo's quiet capture: * the grouped record of otel-collector's `Error scraping metrics` peaked at * 7,811 bytes in a window where its payload came to about 5,900, and * astronomy-db's one-line `FATAL: role "root" does not exist` is 250 bytes a * record against a 69-byte payload. * * Measured when the capture carries the forwarder's records (file mode on * forwarder JSON lines). Otherwise, for a kubectl sample or events read back * from a SIEM's API, each record is the payload plus an assumed metadata * size, stated in the plan. */ /** The regulator's reset window (`rateReceiverResetIntervalMs` 240000). */ export declare const RECEIVER_WINDOW_SECONDS = 240; /** * Forwarder metadata assumed per record when the capture does not carry the * forwarder's records: the median of a 41,694-record EKS capture through * Fluent Bit's kubernetes filter (p10 693, p90 775 bytes). */ export declare const ASSUMED_RECORD_OVERHEAD_BYTES = 760; /** Bytes of a string as a JSON string body: escaped, UTF-8, no quotes. */ export declare function jsonStringBodyBytes(s: string): number; /** Bytes of a record as compact JSON, the form the regulator sizes. */ export declare function compactRecordBytes(rec: unknown): number; export type ReceiverBytesBasis = 'records' | 'assumed_overhead'; /** * How the caps' unit was reached, in one sentence for the plan. `overhead` is * the assumed metadata per record on the assumed path. */ export declare function receiverBytesStatement(basis: ReceiverBytesBasis | undefined, overhead?: number): string;