bug: Creating a new VPC and looking up a resource from an SSM Parameter Value forces CDK redeploy even when there are no changes #10666
Labels
aws:cloudformation
AWS CloudFormation
aws:ec2
Amazon Elastic Compute Cloud
status: backlog
Triaged but not yet being worked on
type: bug
Bug report
Is there an existing issue for this?
Current Behavior
Due to #8222, if you want to use a VPC in your stack you basically have to always use
new Vpc()
, you can't refer to an existing one. However, when you do that in the same stack that you're also doing something along the lines ofQueue.fromArn
where the arn is coming from aStringParameter.valueForStringParameter
then performing acdklocal deploy
on that stack will always trigger a full update of the stack even when there's no diff.Expected Behavior
The stack should realize that there are no changes and not perform the full update
How are you starting LocalStack?
With a docker-compose file
Steps To Reproduce
How are you starting localstack (e.g.,
bin/localstack
command, arguments, ordocker-compose.yml
)Client commands (e.g., AWS SDK code snippet, or sequence of "awslocal" commands)
Environment
Anything else?
I've reproduced the issue here: https://github.com/Garethp/localstack-bugs/tree/vpc-and-lookup-redeploy
If you clone down the branch
vpc-and-lookup-redeploy
, runyarn install
, and then./start.sh
you should see the issue in action.I found isolating this bug confusing and trying to wrap my head around why this might occur also confuses me. If you have only one of either the VPC or the Lookup, it works fine and shows that there's nothing to deploy when you attempt to re-deploy it. It's only when you have both. I assume that other combinations can cause full-stack redeployments, but this is just the first one I found when isolating the issue of getting full-stack redeployments when there are no diff
The text was updated successfully, but these errors were encountered: