LogOptions

class aws_cdk.aws_stepfunctions.LogOptions(*, destination, include_execution_data=None, level=None)

Bases: object

Defines what execution history events are logged and where they are logged.

Parameters
  • destination (ILogGroup) – The log group where the execution history events will be logged.

  • include_execution_data (Optional[bool]) – Determines whether execution data is included in your log. Default: false

  • level (Optional[LogLevel]) – Defines which category of execution history events are logged. Default: ERROR

ExampleMetadata

infused

Example:

import aws_cdk.aws_logs as logs


log_group = logs.LogGroup(self, "MyLogGroup")

sfn.StateMachine(self, "MyStateMachine",
    definition=sfn.Chain.start(sfn.Pass(self, "Pass")),
    logs=sfn.LogOptions(
        destination=log_group,
        level=sfn.LogLevel.ALL
    )
)

Attributes

destination

The log group where the execution history events will be logged.

Return type

ILogGroup

include_execution_data

Determines whether execution data is included in your log.

Default

false

Return type

Optional[bool]

level

Defines which category of execution history events are logged.

Default

ERROR

Return type

Optional[LogLevel]