Class S3OnFailureDestination
An S3 dead letter bucket destination configuration for a Lambda event source.
Inheritance
System.Object
S3OnFailureDestination
Implements
Namespace: Amazon.CDK.AWS.Lambda.EventSources
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class S3OnFailureDestination : DeputyBase, IEventSourceDlq
Syntax (vb)
Public Class S3OnFailureDestination
Inherits DeputyBase
Implements IEventSourceDlq
Remarks
ExampleMetadata: infused
Examples
using Amazon.CDK.AWS.Lambda.EventSources;
using Amazon.CDK.AWS.S3;
IBucket bucket;
Function myFunction;
// Your MSK cluster arn
var clusterArn = "arn:aws:kafka:us-east-1:0123456789019:cluster/SalesCluster/abcd1234-abcd-cafe-abab-9876543210ab-4";
// The Kafka topic you want to subscribe to
var topic = "some-cool-topic";
var s3OnFailureDestination = new S3OnFailureDestination(bucket);
myFunction.AddEventSource(new ManagedKafkaEventSource(new ManagedKafkaEventSourceProps {
ClusterArn = clusterArn,
Topic = topic,
StartingPosition = StartingPosition.TRIM_HORIZON,
OnFailure = s3OnFailureDestination
}));
Synopsis
Constructors
S3OnFailureDestination(IBucket) | |
S3OnFailureDestination(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
S3OnFailureDestination(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
Methods
Bind(IEventSourceMapping, IFunction) | Returns a destination configuration for the DLQ. |
Constructors
S3OnFailureDestination(IBucket)
S3OnFailureDestination(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected S3OnFailureDestination(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
S3OnFailureDestination(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected S3OnFailureDestination(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
Methods
Bind(IEventSourceMapping, IFunction)
Returns a destination configuration for the DLQ.
public virtual IDlqDestinationConfig Bind(IEventSourceMapping target, IFunction targetHandler)
Parameters
- target IEventSourceMapping
- targetHandler IFunction
Returns