aws / aws/aws-cdk

s3-notifications: add option to skip permissions for LambdaDestination

Open
#34,747 2 comments 1 reaction 0 assignees View on GitHub
@aws-cdk/aws-s3-notifications effort/medium feature-request p2
Dominant language
TypeScript
Stars
12.9k
Forks
4.6k
Avg merge
2d 3h
Merged PRs (30d)
83

Description

### Describe the feature

Similar to the `LambdaDestination` in [aws-logs-destinations](https://github.com/aws/aws-cdk/tree/main/packages/aws-cdk-lib/aws-logs-destinations):

https://github.com/aws/aws-cdk/blob/47a3ee3e7590fd085530cd16417fd506c5b9f4d7/packages/aws-cdk-lib/aws-logs-destinations/lib/lambda.ts#L13

I would like to have the same option in the `LambdaDestination` in [aws-s3-notifications](https://github.com/aws/aws-cdk/tree/main/packages/aws-cdk-lib/aws-s3-notifications).

This feature request is similar to https://github.com/aws/aws-cdk/issues/14198

### Use Case

We have an shared Lambda function (acting as a forwarder) that already has all appropriate permissions, and we don't want anyone to be able to change those permissions.

### Proposed Solution

Add an additional option `addPermissions?: boolean`

### Other Information

_No response_

### Acknowledgements

- [x] I may be able to implement this feature request
- [ ] This feature might incur a breaking change

### AWS CDK Library version (aws-cdk-lib)

2.201.0

### AWS CDK CLI version

2.1018.1

### Environment details (OS name and version, etc.)

macOS

Contributor guide

Open the contributing guide

Research direction

Start by reading aws-cdk-lib/aws-logs-destinations/lib/lambda.ts at the referenced implementation, then compare it with the LambdaDestination in aws-cdk-lib/aws-s3-notifications. The work is complete when the S3 notification destination exposes the proposed addPermissions option and existing permission behavior remains unchanged by default.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, typescript
Domain
cloud
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.