You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -1073,6 +1074,27 @@ The `ALBApi` attribute requires an existing ALB listener. Here is a minimal exam
1073
1074
1074
1075
Then your Lambda function references `@MyListener` in the `ALBApi` attribute.
1075
1076
1077
+
## DynamoDB Event Example
1078
+
This example shows how to use the `DynamoDBEvent` attribute to set up event source mapping between a DynamoDB stream and a Lambda function.
1079
+
1080
+
The `DynamoDBEvent` attribute contains the following properties:
1081
+
***Stream** (Required) - The DynamoDB stream ARN or a reference to a DynamoDB table resource prefixed with "@". When using a resource reference, the source generator uses `Fn::GetAtt` to get the `StreamArn`.
1082
+
***ResourceName** (Optional) - The CloudFormation resource name for the event source mapping.
1083
+
***StartingPosition** (Optional) - The position in the stream to start reading. Valid values: `TRIM_HORIZON`, `LATEST`. Default is `LATEST`.
1084
+
***BatchSize** (Optional) - The maximum number of records per batch. Must be between 1 and 10000. Default is 100.
1085
+
***MaximumBatchingWindowInSeconds** (Optional) - Maximum time to gather records before invoking. Must be between 0 and 300.
1086
+
***Enabled** (Optional) - If false, the event source mapping is disabled. Default is true.
1087
+
***Filters** (Optional) - Semicolon-separated filter patterns for event filtering.
Lambda Annotations supports defining custom Lambda authorizers using attributes. Custom authorizers let you control access to your API Gateway endpoints by running a Lambda function that validates tokens or request parameters before the target function is invoked. The source generator automatically wires up the authorizer resources and references in the CloudFormation template.
@@ -1422,6 +1444,9 @@ parameter to the `LambdaFunction` must be the event object and the event source
1422
1444
* Sets up event source mapping between the Lambda function and SQS queues. The SQS queue ARN is required to be set on the attribute. If users want to pass a reference to an existing SQS queue resource defined in their CloudFormation template, they can pass the SQS queue resource name prefixed with the '@' symbol.
1423
1445
* ALBApi
1424
1446
* Configures the Lambda function to be called from an Application Load Balancer. The listener ARN (or `@ResourceName` template reference), path pattern, and priority are required. The source generator creates standalone CloudFormation resources (TargetGroup, ListenerRule, Lambda Permission) rather than SAM event types.
1447
+
* Sets up event source mapping between the Lambda function and SQS queues. The SQS queue ARN is required to be set on the attribute. If users want to pass a reference to an existing SQS queue resource defined in their CloudFormation template, they can pass the SQS queue resource name prefixed with the '@' symbol.
1448
+
* DynamoDBEvent
1449
+
* Sets up event source mapping between the Lambda function and DynamoDB streams. The stream ARN or table resource reference (prefixed with '@') is required.
0 commit comments