Class Runtime
Lambda function runtime environment.
Inheritance
Namespace: Amazon.CDK.AWS.Lambda
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class Runtime : DeputyBase
Syntax (vb)
Public Class Runtime
Inherits DeputyBase
Remarks
If you need to use a runtime name that doesn't exist as a static member, you
can instantiate a Runtime
object, e.g: new Runtime('nodejs99.99')
.
ExampleMetadata: infused
Examples
using Amazon.CDK.AWS.Signer;
var signingProfile = new SigningProfile(this, "SigningProfile", new SigningProfileProps {
Platform = Platform.AWS_LAMBDA_SHA384_ECDSA
});
var codeSigningConfig = new CodeSigningConfig(this, "CodeSigningConfig", new CodeSigningConfigProps {
SigningProfiles = new [] { signingProfile }
});
new Function(this, "Function", new FunctionProps {
CodeSigningConfig = codeSigningConfig,
Runtime = Runtime.NODEJS_18_X,
Handler = "index.handler",
Code = Code.FromAsset(Join(__dirname, "lambda-handler"))
});
Synopsis
Constructors
Runtime(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
Runtime(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
Runtime(String, Nullable<RuntimeFamily>, ILambdaRuntimeProps) |
Properties
ALL | A list of all known |
BundlingImage | The bundling Docker image for this runtime. |
DOTNET_6 | The .NET 6 runtime (dotnet6). |
DOTNET_8 | The .NET 8 runtime (dotnet8). |
DOTNET_CORE_1 | (deprecated) The .NET Core 1.0 runtime (dotnetcore1.0). |
DOTNET_CORE_2 | (deprecated) The .NET Core 2.0 runtime (dotnetcore2.0). |
DOTNET_CORE_2_1 | (deprecated) The .NET Core 2.1 runtime (dotnetcore2.1). |
DOTNET_CORE_3_1 | (deprecated) The .NET Core 3.1 runtime (dotnetcore3.1). |
Family | The runtime family. |
FROM_IMAGE | A special runtime entry to be used when function is using a docker image. |
GO_1_X | (deprecated) The Go 1.x runtime (go1.x). |
IsVariable | Enabled for runtime enums that always target the latest available. |
JAVA_11 | The Java 11 runtime (java11). |
JAVA_17 | The Java 17 runtime (java17). |
JAVA_21 | The Java 21 runtime (java21). |
JAVA_8 | (deprecated) The Java 8 runtime (java8). |
JAVA_8_CORRETTO | The Java 8 Corretto runtime (java8.al2). |
Name | The name of this runtime, as expected by the Lambda resource. |
NODEJS | (deprecated) The NodeJS runtime (nodejs). |
NODEJS_10_X | (deprecated) The NodeJS 10.x runtime (nodejs10.x). |
NODEJS_12_X | (deprecated) The NodeJS 12.x runtime (nodejs12.x). |
NODEJS_14_X | (deprecated) The NodeJS 14.x runtime (nodejs14.x). |
NODEJS_16_X | The NodeJS 16.x runtime (nodejs16.x). |
NODEJS_18_X | The NodeJS 18.x runtime (nodejs18.x). |
NODEJS_20_X | The NodeJS 20.x runtime (nodejs20.x). |
NODEJS_4_3 | (deprecated) The NodeJS 4.3 runtime (nodejs4.3). |
NODEJS_6_10 | (deprecated) The NodeJS 6.10 runtime (nodejs6.10). |
NODEJS_8_10 | (deprecated) The NodeJS 8.10 runtime (nodejs8.10). |
NODEJS_LATEST | The latest NodeJS version currently available in ALL regions (not necessarily the latest NodeJS version available in YOUR region). |
PROVIDED | (deprecated) The custom provided runtime (provided). |
PROVIDED_AL2 | The custom provided runtime with Amazon Linux 2 (provided.al2). |
PROVIDED_AL2023 | The custom provided runtime with Amazon Linux 2023 (provided.al2023). |
PYTHON_2_7 | (deprecated) The Python 2.7 runtime (python2.7). |
PYTHON_3_10 | The Python 3.10 runtime (python3.10). |
PYTHON_3_11 | The Python 3.11 runtime (python3.11). |
PYTHON_3_12 | The Python 3.12 runtime (python3.12). |
PYTHON_3_6 | (deprecated) The Python 3.6 runtime (python3.6) (not recommended). |
PYTHON_3_7 | (deprecated) The Python 3.7 runtime (python3.7). |
PYTHON_3_8 | The Python 3.8 runtime (python3.8). |
PYTHON_3_9 | The Python 3.9 runtime (python3.9). |
RUBY_2_5 | (deprecated) The Ruby 2.5 runtime (ruby2.5). |
RUBY_2_7 | (deprecated) The Ruby 2.7 runtime (ruby2.7). |
RUBY_3_2 | The Ruby 3.2 runtime (ruby3.2). |
RUBY_3_3 | The Ruby 3.3 runtime (ruby3.3). |
SupportsCodeGuruProfiling | Whether this runtime is integrated with and supported for profiling using Amazon CodeGuru Profiler. |
SupportsInlineCode | Whether the |
SupportsSnapStart | Whether this runtime supports snapstart. |
Methods
RuntimeEquals(Runtime) | |
ToString() |
Constructors
Runtime(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected Runtime(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
Runtime(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected Runtime(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
Runtime(String, Nullable<RuntimeFamily>, ILambdaRuntimeProps)
public Runtime(string name, Nullable<RuntimeFamily> family = null, ILambdaRuntimeProps props = null)
Parameters
- name System.String
- family System.Nullable<RuntimeFamily>
- props ILambdaRuntimeProps
Properties
ALL
BundlingImage
The bundling Docker image for this runtime.
public virtual DockerImage BundlingImage { get; }
Property Value
DOTNET_6
DOTNET_8
DOTNET_CORE_1
(deprecated) The .NET Core 1.0 runtime (dotnetcore1.0).
public static Runtime DOTNET_CORE_1 { get; }
Property Value
Remarks
Stability: Deprecated
DOTNET_CORE_2
(deprecated) The .NET Core 2.0 runtime (dotnetcore2.0).
public static Runtime DOTNET_CORE_2 { get; }
Property Value
Remarks
Stability: Deprecated
DOTNET_CORE_2_1
(deprecated) The .NET Core 2.1 runtime (dotnetcore2.1).
public static Runtime DOTNET_CORE_2_1 { get; }
Property Value
Remarks
Stability: Deprecated
DOTNET_CORE_3_1
(deprecated) The .NET Core 3.1 runtime (dotnetcore3.1).
public static Runtime DOTNET_CORE_3_1 { get; }
Property Value
Remarks
Stability: Deprecated
Family
The runtime family.
public virtual Nullable<RuntimeFamily> Family { get; }
Property Value
System.Nullable<RuntimeFamily>
FROM_IMAGE
A special runtime entry to be used when function is using a docker image.
public static Runtime FROM_IMAGE { get; }
Property Value
GO_1_X
(deprecated) The Go 1.x runtime (go1.x).
public static Runtime GO_1_X { get; }
Property Value
Remarks
Stability: Deprecated
IsVariable
Enabled for runtime enums that always target the latest available.
public virtual bool IsVariable { get; }
Property Value
System.Boolean
JAVA_11
JAVA_17
JAVA_21
JAVA_8
(deprecated) The Java 8 runtime (java8).
public static Runtime JAVA_8 { get; }
Property Value
Remarks
Stability: Deprecated
JAVA_8_CORRETTO
The Java 8 Corretto runtime (java8.al2).
public static Runtime JAVA_8_CORRETTO { get; }
Property Value
Name
The name of this runtime, as expected by the Lambda resource.
public virtual string Name { get; }
Property Value
System.String
NODEJS
(deprecated) The NodeJS runtime (nodejs).
public static Runtime NODEJS { get; }
Property Value
Remarks
Stability: Deprecated
NODEJS_10_X
(deprecated) The NodeJS 10.x runtime (nodejs10.x).
public static Runtime NODEJS_10_X { get; }
Property Value
Remarks
Stability: Deprecated
NODEJS_12_X
(deprecated) The NodeJS 12.x runtime (nodejs12.x).
public static Runtime NODEJS_12_X { get; }
Property Value
Remarks
Stability: Deprecated
NODEJS_14_X
(deprecated) The NodeJS 14.x runtime (nodejs14.x).
public static Runtime NODEJS_14_X { get; }
Property Value
Remarks
Stability: Deprecated
NODEJS_16_X
The NodeJS 16.x runtime (nodejs16.x).
public static Runtime NODEJS_16_X { get; }
Property Value
NODEJS_18_X
The NodeJS 18.x runtime (nodejs18.x).
public static Runtime NODEJS_18_X { get; }
Property Value
NODEJS_20_X
The NodeJS 20.x runtime (nodejs20.x).
public static Runtime NODEJS_20_X { get; }
Property Value
NODEJS_4_3
(deprecated) The NodeJS 4.3 runtime (nodejs4.3).
public static Runtime NODEJS_4_3 { get; }
Property Value
Remarks
Stability: Deprecated
NODEJS_6_10
(deprecated) The NodeJS 6.10 runtime (nodejs6.10).
public static Runtime NODEJS_6_10 { get; }
Property Value
Remarks
Stability: Deprecated
NODEJS_8_10
(deprecated) The NodeJS 8.10 runtime (nodejs8.10).
public static Runtime NODEJS_8_10 { get; }
Property Value
Remarks
Stability: Deprecated
NODEJS_LATEST
The latest NodeJS version currently available in ALL regions (not necessarily the latest NodeJS version available in YOUR region).
public static Runtime NODEJS_LATEST { get; }
Property Value
PROVIDED
(deprecated) The custom provided runtime (provided).
public static Runtime PROVIDED { get; }
Property Value
Remarks
Stability: Deprecated
PROVIDED_AL2
The custom provided runtime with Amazon Linux 2 (provided.al2).
public static Runtime PROVIDED_AL2 { get; }
Property Value
PROVIDED_AL2023
The custom provided runtime with Amazon Linux 2023 (provided.al2023).
public static Runtime PROVIDED_AL2023 { get; }
Property Value
PYTHON_2_7
(deprecated) The Python 2.7 runtime (python2.7).
public static Runtime PYTHON_2_7 { get; }
Property Value
Remarks
Stability: Deprecated
PYTHON_3_10
The Python 3.10 runtime (python3.10).
public static Runtime PYTHON_3_10 { get; }
Property Value
PYTHON_3_11
The Python 3.11 runtime (python3.11).
public static Runtime PYTHON_3_11 { get; }
Property Value
PYTHON_3_12
The Python 3.12 runtime (python3.12).
public static Runtime PYTHON_3_12 { get; }
Property Value
PYTHON_3_6
(deprecated) The Python 3.6 runtime (python3.6) (not recommended).
public static Runtime PYTHON_3_6 { get; }
Property Value
Remarks
The Python 3.6 runtime is deprecated as of July 2022.
Stability: Deprecated
PYTHON_3_7
(deprecated) The Python 3.7 runtime (python3.7).
public static Runtime PYTHON_3_7 { get; }
Property Value
Remarks
Stability: Deprecated
PYTHON_3_8
The Python 3.8 runtime (python3.8).
public static Runtime PYTHON_3_8 { get; }
Property Value
PYTHON_3_9
The Python 3.9 runtime (python3.9).
public static Runtime PYTHON_3_9 { get; }
Property Value
RUBY_2_5
(deprecated) The Ruby 2.5 runtime (ruby2.5).
public static Runtime RUBY_2_5 { get; }
Property Value
Remarks
Stability: Deprecated
RUBY_2_7
(deprecated) The Ruby 2.7 runtime (ruby2.7).
public static Runtime RUBY_2_7 { get; }
Property Value
Remarks
Stability: Deprecated
RUBY_3_2
RUBY_3_3
SupportsCodeGuruProfiling
Whether this runtime is integrated with and supported for profiling using Amazon CodeGuru Profiler.
public virtual bool SupportsCodeGuruProfiling { get; }
Property Value
System.Boolean
SupportsInlineCode
Whether the ZipFile
(aka inline code) property can be used with this runtime.
public virtual bool SupportsInlineCode { get; }
Property Value
System.Boolean
SupportsSnapStart
Whether this runtime supports snapstart.
public virtual bool SupportsSnapStart { get; }
Property Value
System.Boolean
Methods
RuntimeEquals(Runtime)
ToString()
public override string ToString()
Returns
System.String