durable-execution-sdk-js.durablelogger.md

December 2, 2025 ยท View on GitHub

Home > @aws/durable-execution-sdk-js > DurableLogger

DurableLogger interface

This interface provides structured logging capabilities for durable execution contexts. A custom logger must implement this interface to be used by the Durable Execution Language SDK. The SDK will automatically parse the logger and use the appropriate logging method based on the log level.

Signature:

export interface DurableLogger

Methods

Method

Description

configureDurableLoggingContext(durableLoggingContext)?

(Optional) This function will be called by the language SDK before logging any records. The durableLoggingContext should be stored and used by custom loggers to enable logging of custom durable metadata such as operationId, attempt, executionArn, etc.

debug(params)

Log debug messages with optional additional parameters

error(params)

Log error messages with optional message and additional parameters

info(params)

Log informational messages with optional additional parameters

log(level, params)?

(Optional) Generic log method with configurable level

warn(params)

Log warning messages with optional additional parameters