Derek Kershner
01/13/2022, 4:53 PM0.53.2
to 0.58.0
. No other actions.
Symptoms:
staging-ResonanceWebAppAdminIdentity-AdminIdentityWebAppStack | CREATE_FAILED | AWS::Lambda::Version | AdminIdentityWebAppNextJsSiteApiFunctionCurrentVersion42206DF251f45f4f60760bb3fec1986818833736 | A version for this Lambda function exists ( 2 ). Modify the function to create a new version.
staging-ResonanceWebAppAdminIdentity-AdminIdentityWebAppStack | CREATE_FAILED | AWS::Lambda::Version | AdminIdentityWebAppNextJsSiteImageFunctionCurrentVersionFEA047D3cea01b8892c8bacfeceb61e122debf40 | A version for this Lambda function exists ( 2 ). Modify the function to create a new version.
staging-ResonanceWebAppAdminIdentity-AdminIdentityWebAppStack | UPDATE_FAILED | AWS::Lambda::Function | AdminIdentityWebAppNextJsSiteMainFunctionCFE178A8 | Resource update cancelled
Derek Kershner
01/13/2022, 4:56 PMFrank
Frank
Derek Kershner
01/13/2022, 4:58 PMDerek Kershner
01/13/2022, 4:59 PMNextJsSite
, and I dont use Next.js API functionality.Derek Kershner
01/13/2022, 4:59 PMImage
, thoughDerek Kershner
01/13/2022, 4:59 PMFrank
new NextjsSite(this, "Site", {
path: "path/to/site",
defaultFunctionProps: {
memorySize: 2048,
},
});
That should create a different version.Frank
Derek Kershner
01/13/2022, 5:02 PMDerek Kershner
01/13/2022, 5:15 PMDerek Kershner
01/13/2022, 5:17 PMDerek Kershner
01/13/2022, 5:23 PMDerek Kershner
01/20/2022, 9:08 PMDerek Kershner
01/20/2022, 9:09 PMDerek Kershner
01/20/2022, 9:27 PMFrank
Frank
"Metadata": {
"aws:cdk:path": "...",
"aws:asset:path": "...",
"aws:asset:property": "Code"
}
And later they added a new field:
"Metadata": {
"aws:cdk:path": "...",
"aws:asset:path": "...",
"aws:asset:is-bundled": false,
"aws:asset:property": "Code"
}
CDK thinks the Lambda function changed, and generated a new version. But since the Lambda function’s code/config didn’t really change, AWS Lambda rejected the deploy with the error A version for this Lambda function exists
According to the GitHub issue, this should’ve been fixed.Derek Kershner
02/10/2022, 9:32 PM