You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Presently when the 'AutoPublishAlias' is set in the template for the Serverless Function, then during each update on the Function code publishes new Lambda Function Version. However, if we make only changes to the Lambda layer code and then deploy the changes through SAM-CLI. The new Lambda Function Version is not published and thus the Lambda function would still be using the older version of the Lambda Layer.
So it would be great if a new property similar to 'AutoPublishAlias' is created for the scenario where the Update only on the Lambda layer should publish a new version of the lambda Function.
Steps to reproduce the issue:
Create a SAM application with a Layer and then build & deploy it using SAM-CLI. (commands 'sam-build' & 'sam deploy')
Next update the Lambda Layer code only and again run the commands 'sam-build' & 'sam deploy'.
Observed result:
The Lambda Layer is updated to a newer version and also the Lambda function with $LATEST version gets the Layer version updated. However the changes in Layer does not get reflected as the new version of Lambda function is not published.
Expected result:
The Lambda Layer is updated to a newer version and the new version of the Lambda Function is published .
The text was updated successfully, but these errors were encountered:
Hi @hnbalach Thanks for your feature request!
After trying with your template, I think the problem you observed is actually a bug that's reported in #1640.
Closing in favor of #1640
Description:
Presently when the 'AutoPublishAlias' is set in the template for the Serverless Function, then during each update on the Function code publishes new Lambda Function Version. However, if we make only changes to the Lambda layer code and then deploy the changes through SAM-CLI. The new Lambda Function Version is not published and thus the Lambda function would still be using the older version of the Lambda Layer.
So it would be great if a new property similar to 'AutoPublishAlias' is created for the scenario where the Update only on the Lambda layer should publish a new version of the lambda Function.
Steps to reproduce the issue:
SAM template ->
Observed result:
The Lambda Layer is updated to a newer version and also the Lambda function with $LATEST version gets the Layer version updated. However the changes in Layer does not get reflected as the new version of Lambda function is not published.
Expected result:
The Lambda Layer is updated to a newer version and the new version of the Lambda Function is published .
The text was updated successfully, but these errors were encountered: