When creating multiple lambda functions simultaneously, the creation sometimes fails with below error:
Resource handler returned message: "Function creation failed because the function already exists"
Expected Behavior
Lambda with the same name does not exist in the account, however it stills fails with function exists error
Observed Behavior
Upon checking Cloudtrail it was found that CFN is sometimes making 2 'CreateFunction' API calls for the same lambda. First one is getting successful however the second call is failing with above error.
Test Cases
Try creating 10-15 stacks in parallel. Each with an average of 10-15 lambdas.
Other Details
As per AWS Support, there is an internal bug. So creating this github issue to track this publicly.
Note: Sequential deployment of the stacks and using DependsOn is not suitable for our use case.
Name of the resource
AWS::Lambda::Function
Resource Name
No response
Issue Description
When creating multiple lambda functions simultaneously, the creation sometimes fails with below error:
Expected Behavior
Lambda with the same name does not exist in the account, however it stills fails with function exists error
Observed Behavior
Upon checking Cloudtrail it was found that CFN is sometimes making 2 'CreateFunction' API calls for the same lambda. First one is getting successful however the second call is failing with above error.
Test Cases
Try creating 10-15 stacks in parallel. Each with an average of 10-15 lambdas.
Other Details
As per AWS Support, there is an internal bug. So creating this github issue to track this publicly.
Note: Sequential deployment of the stacks and using DependsOn is not suitable for our use case.