LogRecord
interface exported by @mwillbanks/tuil-logging.
interface
Public interface exported by @mwillbanks/tuil-logging.
export interface LogRecord {
readonly timestamp?: bigint;
readonly observedTimestamp?: bigint;
readonly severityNumber?: number;
readonly severityText?: string;
readonly body: unknown;
readonly attributes: Readonly<Record<string, unknown>>;
readonly resource: Readonly<Record<string, unknown>>;
readonly scope?: {
readonly name?: string;
readonly version?: string;
};
readonly traceId?: string;
readonly spanId?: string;
readonly flags?: number;
readonly eventName?: string;
readonly source: LogSource;
readonly original: unknown;
readonly diagnostics: readonly LogDiagnostic[];
readonly duplicateCount?: number;
readonly rateLimited?: boolean;
readonly sampled?: boolean;
}Members
| Member | Type | Required | Description | Related types |
|---|---|---|---|---|
timestamp | bigint | undefined | No | The timestamp member uses the bigint | undefined contract. | — |
observedTimestamp | bigint | undefined | No | The observedTimestamp member uses the bigint | undefined contract. | — |
severityNumber | number | undefined | No | The severityNumber member uses the number | undefined contract. | — |
severityText | string | undefined | No | The severityText member uses the string | undefined contract. | — |
body | unknown | Yes | The body member uses the unknown contract. | — |
attributes | Readonly<Record<string, unknown>> | Yes | The attributes member uses the Readonly<Record<string, unknown>> contract. | — |
resource | Readonly<Record<string, unknown>> | Yes | The resource member uses the Readonly<Record<string, unknown>> contract. | — |
scope | { readonly name?: string; readonly version?: string; } | undefined | No | The scope member uses the { readonly name?: string; readonly version?: string; } | undefined contract. | — |
traceId | string | undefined | No | The traceId member uses the string | undefined contract. | — |
spanId | string | undefined | No | The spanId member uses the string | undefined contract. | — |
flags | number | undefined | No | The flags member uses the number | undefined contract. | — |
eventName | string | undefined | No | The eventName member uses the string | undefined contract. | — |
source | LogSource | Yes | The source member uses the LogSource contract. | LogSource |
original | unknown | Yes | The original member uses the unknown contract. | — |
diagnostics | readonly LogDiagnostic[] | Yes | The diagnostics member uses the readonly LogDiagnostic[] contract. | LogDiagnostic |
duplicateCount | number | undefined | No | The duplicateCount member uses the number | undefined contract. | — |
rateLimited | boolean | undefined | No | The rateLimited member uses the boolean | undefined contract. | — |
sampled | boolean | undefined | No | The sampled member uses the boolean | undefined contract. | — |
Parameters
This declaration has no public members.
Returns
This declaration does not return a value.
Throws
No thrown errors are documented for this declaration.
Related types
Source
View the secondary source reference