Deployment , and rollback, fails when removing ProvisionedConcurrency configuration from Function
If you remove the ProvisionedConcurrencyConfig section from an existing AWS::Serverless::Function resource then deployment fails with the message:
"Alias with weights can not be used with Provisioned Concurrency (Service: AWSLambdaInternal; Status Code: 400; Error Code: InvalidParameterValueException; Request ID: ...)"
What's especially nasty about this is that the CloudFormation rollback then fails, leaving the stack in UPDATE_ROLLBACK_FAILED state, and sam deploy never finishes.
I'm not impacted by this in production - I'm only experimenting - but I thought you all might want to know.
For reference my initial SAM resource was:
HelloWorldLambda:
Type: AWS::Serverless::Function
Properties:
Runtime: java8
MemorySize: 512
Handler: book.HelloWorld::handler
CodeUri: target/lambda.jar
AutoPublishAlias: live
ProvisionedConcurrencyConfig:
ProvisionedConcurrentExecutions: 100
And I then removed the ProvisionedConcurrencyConfig (and child ProvisionedConcurrentExecutions) property.
Mike