-
Notifications
You must be signed in to change notification settings - Fork 4.2k
feat(lambda-event-sources): Add eventsourceMappingArn to IEventSourceMapping #24991
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The pull request linter has failed. See the aws-cdk-automation comment below for failure reasons. If you believe this pull request should receive an exemption, please comment and provide a justification.
A comment requesting an exemption should contain the text Exemption Request
. Additionally, if clarification is needed add Clarification Request
to a comment.
✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
3 similar comments
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
@pahud Can you or somebody else please have a look? I've rebased the branch. Sidenote: I had quite a struggle, rebasing the changes, since there are a lot of changes going through this repo in 2 weeks 🙈 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Thanks for the PR!
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
Thank you for taking a look @corymhall :) 🙏 |
Currently the eventsourceMappingArn (for example for SQS Lambda Trigger) needs to be constructed manually:
arn:aws:lambda:eu-west-1:ACCOUNT_ID:event-source-mapping:EVENTSOURCEMAPPINGID
With this change its no longer needed to construct it manually.
The solution now exposes the
eventSourceMappingArn
on theIEventSourceMapping
. The ARN is constructed by the individual components (service, resource, resourceName/eventSourceMappingId
andformat
).I considered adding a static method
fromEventSourceMappingArn
to theEventSourceMapping
class. Wasnt sure if it provides any value, but let me know if you think its a good Idea to add it.Sidenote:I had a bit of a struggle to build the project (during development I had a lot of heap memory issues).
Additionally I wasnt able to execute the integration tests, I tried to follow https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md#running-integration-tests but either I make something wrong or the guide seems out of date? Would be great if I get some pointers in the right direction.
Closes #24801 .
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license