- Clone this repo
- Run
npm install
- Run
npm run cdk synth
- Open the generated template
cdk.out/MyStack.template.json
and notice the logical id of the lambda version isMyLambdaCurrentVersionE7A382CC40566d291e26de5fbeddf64c72bb9661
- Open
package.json
and change the version of bothaws-cdk
andaws-csk-lib
to2.88.0
- Run
npm install
- Run
npm run cdk synth
- Open the generated template
cdk.out/MyStack.template.json
and notice the logical id of the lambda version is changed toMyLambdaCurrentVersionE7A382CC6466d36c9d15346e31eee2175be4ea3e
The change in logical id of the lambda version causes a deployment failure by CloudFormation because nothing has been changed to the lambda function nor the layer version.
Note: The logical id of the lambda version remains stable if the lambda function has no layers