Class: AWSCDK::Lambda::CfnEventSourceMapping::OnFailureProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
lambda/cfn_event_source_mapping.rb

Overview

A destination for events that failed processing.

For more information, see Adding a destination .

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(destination: nil) ⇒ OnFailureProperty

Returns a new instance of OnFailureProperty.

Parameters:

  • destination (String, nil) (defaults to: nil)

    The Amazon Resource Name (ARN) of the destination resource.



1214
1215
1216
1217
# File 'lambda/cfn_event_source_mapping.rb', line 1214

def initialize(destination: nil)
  @destination = destination
  Jsii::Type.check_type(@destination, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "destination") unless @destination.nil?
end

Instance Attribute Details

#destinationString? (readonly)

The Amazon Resource Name (ARN) of the destination resource.

To retain records of failed invocations from Kinesis , DynamoDB , self-managed Apache Kafka , or Amazon MSK , you can configure an Amazon SNS topic, Amazon SQS queue, Amazon S3 bucket, or Kafka topic as the destination.

Amazon SNS destinations have a message size limit of 256 KB. If the combined size of the function request and response payload exceeds the limit, Lambda will drop the payload when sending OnFailure event to the destination. For details on this behavior, refer to Retaining records of asynchronous invocations .

To retain records of failed invocations from Kinesis , DynamoDB , self-managed Kafka or Amazon MSK , you can configure an Amazon SNS topic, Amazon SQS queue, or Amazon S3 bucket as the destination.



1229
1230
1231
# File 'lambda/cfn_event_source_mapping.rb', line 1229

def destination
  @destination
end

Class Method Details

.jsii_propertiesObject



1231
1232
1233
1234
1235
# File 'lambda/cfn_event_source_mapping.rb', line 1231

def self.jsii_properties
  {
    :destination => "destination",
  }
end

Instance Method Details

#to_jsiiObject



1237
1238
1239
1240
1241
1242
1243
# File 'lambda/cfn_event_source_mapping.rb', line 1237

def to_jsii
  result = {}
  result.merge!({
    "destination" => @destination,
  })
  result.compact
end