A stack has been in `CREATE_IN_PROGRESS` for an hour on a `Custom::DbSeeder` resource.
AdvancedTroubleshootingCloudFormation, CloudWatch, KMS, Secrets and Cost
Answer
Likely causes → The custom resource Lambda never sent a response to the pre-signed ResponseURL. It crashed, timed out, could not reach S3 (in a VPC without NAT or an endpoint), or forgot to answer on Delete. CloudFormation waits up to the service timeout, which is one hour by default.
Diagnose →
aws cloudformation describe-stack-resource --stack-name app --logical-resource-id DbSeeder
aws logs tail /aws/lambda/app-DbSeeder --since 2h
Fix →
- To unblock now, send a response yourself with
curl -X PUT -H 'Content-Type:' --data-binary '{"Status":"FAILURE","Reason":"manual","PhysicalResourceId":"seed","StackId":"...","RequestId":"...","LogicalResourceId":"DbSeeder"}' "<ResponseURL from logs>" - Fix the handler so it always responds in
try/finally, including on Delete
Prevent → Use the cfn-response module or CDK Provider framework, and set ServiceTimeout on the custom resource to something short (for example, 300 seconds).
More on CloudFormation, CloudWatch, KMS, Secrets and Cost
Updating a stack fails: `Stack:arn:aws:cloudformation:...:stack/app/... is in ROLLBACK_COMPLETE state and can not be updated.`BeginnerA stack is stuck in `UPDATE_ROLLBACK_FAILED`.AdvancedA pipeline fails with `An error occurred (ValidationError) when calling the UpdateStack operation: No updates are to be performed.`Beginner`InsufficientCapabilitiesException: Requires capabilities : [CAPABILITY_NAMED_IAM]`.BeginnerStack deletion ends in `DELETE_FAILED` with `The bucket you tried to delete is not empty` on an S3 bucket resource.IntermediateDrift detection shows `MODIFIED` on a security group and an RDS instance that someone changed in the console. How do you reconcile?Advanced