Remediation
Migrate the Lambda Function to a Supported Runtimeβ
When an AWS Lambda runtime is deprecated, AWS blocks the creation of new functions and the updating of existing functions that use the deprecated runtime shortly after deprecation. As a result, remediation typically requires creating a new Lambda function using a supported runtime.
From Command Lineβ
-
Review the list of supported AWS Lambda runtimes and select the appropriate target runtime version: https://docs.aws.amazon.com/lambda/latest/dg/lambda-runtimes.html#runtimes-supported
-
Update the function code to be compatible with the selected runtime. This may include modifying language syntax, replacing deprecated APIs, and updating third-party dependencies or Lambda layers.
-
Create a new Lambda function using the updated code and a supported runtime:
aws lambda create-function \
--function-name {{new-function-name}} \
--runtime {{latest-runtime-version}} \
--role {{execution-role-arn}} \
--handler {{handler-name}} \
--zip-file fileb://{{deployment-package.zip}} -
Validate that the new function executes successfully and behaves as expected.
-
Update any event source mappings, triggers, environment variables, permissions, or downstream integrations to reference the new function.
-
After verification, decommission the original function running on the deprecated runtime.