-
Notifications
You must be signed in to change notification settings - Fork 4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(lambda): support for Provisioned Pollers (#32205)
### Reason for this change Lambda is introducing a new property in Event Sources named `ProvisionedPollerConfig` to set provisioned pollers that read from the event sources. When specified, it allows control over the minimum and maximum number of pollers that can be provisioned to process events from the source. This feature is currently supported for MSK and Self-managed Kafka event sources. ### Description of changes This new property can be opted in by setting the `ProvisionedPollerConfig` field while creating event sources. The example of setting `ProvisionedPollerConfig` for is shown below: ``` fn.addEventSource(new sources.ManagedKafkaEventSource( { clusterArn, topic: kafkaTopic, startingPosition: lambda.StartingPosition.TRIM_HORIZON, provisionedPollerConfig: { minimumPollers: 1, maximumPollers: 3, }, })) ``` ### Description of how you validated changes Have added unit test and integration test to validate the implementation ### Checklist - [x] My code adheres to the [CONTRIBUTING GUIDE](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) and [DESIGN GUIDELINES](https://github.com/aws/aws-cdk/blob/main/docs/DESIGN_GUIDELINES.md) ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
- Loading branch information
1 parent
e1195f9
commit 68b969e
Showing
15 changed files
with
781 additions
and
11 deletions.
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
...snapshot/LambdaEventSourceKafkaSelfManagedTestDefaultTestDeployAssertAF78BD0F.assets.json
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
2 changes: 1 addition & 1 deletion
2
...work-integ/test/aws-lambda-event-sources/test/integ.kafka-selfmanaged.js.snapshot/cdk.out
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
2 changes: 1 addition & 1 deletion
2
...k-integ/test/aws-lambda-event-sources/test/integ.kafka-selfmanaged.js.snapshot/integ.json
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
6 changes: 3 additions & 3 deletions
6
...st/integ.kafka-selfmanaged.js.snapshot/lambda-event-source-kafka-self-managed.assets.json
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 28 additions & 2 deletions
30
...nteg/test/aws-lambda-event-sources/test/integ.kafka-selfmanaged.js.snapshot/manifest.json
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.