@aws-cdk/aws-appsync-alpha: GraphqlApi - Support web ACL assignment
- Dominant language
- TypeScript
- Stars
- 12.9k
- Forks
- 4.6k
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 71
Description
### Describe the feature
When using the GraphqlApi resource it is a best practice to attach Web access control lists (web ACLs) to the API since it is publicly exposed.
It would be great to allow a direct assignment of the web ACL to the resource.
### Use Case
With the current implementation it is not possible to directly assign web ACL, but you will need to create first the API and then create another L1 resource (CfnWebACLAssociation) which then assigns the web ACL to the API.
This creates unnecessary lines of code and would be much easier by setting it via a dedicated construct props.
### Proposed Solution
Allow to directly assign the web ACL rules via a construct props as done for example within the [Cloudfront Distribution resource](https://docs.aws.amazon.com/cdk/api/v1/docs/@aws-cdk_aws-cloudfront.Distribution.html) with prop "webAclId".
### Other Information
Version
- @aws-cdk/aws-appsync-alpha": "2.45.0-alpha.0"
### Acknowledgements
- [ ] I may be able to implement this feature request
- [ ] This feature might incur a breaking change
### CDK version used
2.55.1
### Environment details (OS name and version, etc.)
Windows 10
Contributor guide
Research direction
Start by locating the GraphqlApi construct in the @aws-cdk/aws-appsync-alpha package and compare its props with the CloudFront Distribution webAclId pattern described in the issue. Read how CfnWebACLAssociation is currently used, then add coverage showing that a web ACL can be assigned through the construct props and that the resulting association is synthesized.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, typescript
- Domain
- api, cloud, security
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100