Skip to content
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

lambda: addAlias method fails when there are more than one lambda functions in a stack #25623

Closed
1 of 2 tasks
ericxinzhang opened this issue May 17, 2023 · 3 comments
Closed
1 of 2 tasks
Labels
@aws-cdk/aws-lambda Related to AWS Lambda feature-request A feature should be added or improved. p2 response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days.

Comments

@ericxinzhang
Copy link

Describe the feature

At the moment the lambda function addAlias method link composes the logic name as Alias${aliasName} which causes error when there are multiple lambda functions in a stack with same alias.

Use Case

I would like to use the SnapStart feature therefore needs to add an alias to all my lambda functions. However I can't use addAlias method because of the duplicate logical name.

Proposed Solution

I'd suggest that the alias name is derived from not only the alias name itself, but also the lambda version so as to make it more unique.

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

CDK version used

2.79.1

Environment details (OS name and version, etc.)

MacOS

@ericxinzhang ericxinzhang added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels May 17, 2023
@github-actions github-actions bot added the @aws-cdk/aws-lambda Related to AWS Lambda label May 17, 2023
@peterwoodworth
Copy link
Contributor

The scope of these should be different, no? Could you provide reproduction code please?

@peterwoodworth peterwoodworth added p2 response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. and removed needs-triage This issue or PR still needs to be triaged. labels May 18, 2023
@ericxinzhang
Copy link
Author

My apology - it's a false alarm.

@github-actions
Copy link

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-lambda Related to AWS Lambda feature-request A feature should be added or improved. p2 response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days.
Projects
None yet
Development

No branches or pull requests

2 participants