Skip to content

@statesync/core


@statesync/core / Logger

Interface: Logger ​

Defined in: types.ts:206

A minimal structured logging interface used by the sync engine.

Implementations can delegate to console, a logging library, or a telemetry pipeline. The extra parameter carries structured context (topic, revision, error, etc.) and is intentionally unknown so that any serializable data can be passed through.

See ​

Methods ​

debug() ​

ts
debug(msg, extra?): void;

Defined in: types.ts:213

Logs a debug-level message. Typically used for tracing sync lifecycle events.

Parameters ​

ParameterTypeDescription
msgstringA human-readable log message.
extra?unknownOptional structured context for the log entry.

Returns ​

void


error() ​

ts
error(msg, extra?): void;

Defined in: types.ts:227

Logs an error-level message. Used for failures in the sync pipeline.

Parameters ​

ParameterTypeDescription
msgstringA human-readable log message.
extra?unknownOptional structured context for the log entry.

Returns ​

void


warn() ​

ts
warn(msg, extra?): void;

Defined in: types.ts:220

Logs a warning-level message. Used for non-fatal issues such as retry attempts.

Parameters ​

ParameterTypeDescription
msgstringA human-readable log message.
extra?unknownOptional structured context for the log entry.

Returns ​

void

Released under the MIT License.