Context class

Context contains the Lambda execution context information. They are either provided via Platform.environment or NextInvocation which is the result from the Lambda API.

Note: this should not be used directly.

Constructors

Context({String handler, String functionName, String functionMemorySize, String logGroupName, String logStreamName, String requestId, String invokedFunction, String region, String executionEnv, String accessKey, String secretAccessKey, String sessionToken})

Properties

accessKey String
Access key that is acquired via STS.
read / write
executionEnv String
The execution environment of the function.
read / write
functionMemorySize String
Memory sized that is allocated to execution of the function.
read / write
functionName String
Name of the function that is invoked.
read / write
functionVersion String
Version of the function that is invoked.
read / write
handler String
Handler that is used for the invocation of the function
read / write
hashCode int
The hash code for this object. [...]
read-only, inherited
invokedFunctionArn String
The ARN to identify the function.
read / write
logGroupName String
Cloudwatch LogGroup that is associated with the Lambda.
read / write
logStreamName String
Cloudwach LogStream that is associated with the Lambda.
read / write
region String
Region that this function exists in.
read / write
requestId String
Id of the request. You can use this to track the request for the invocation.
read / write
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
secretAccessKey String
Secret access key that is acquired via STS.
read / write
sessionToken String
The session token from STS.
read / write

Methods

copyWith({String handler, String functionName, String functionMemorySize, String logGroupName, String logStreamName, String requestId, String invokedFunction, String region, String executionEnv, String accessKey, String secretAccessKey, String sessionToken}) Context
Allows to copy a created Context over with some new settings.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() String
Returns a string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator. [...]
inherited

Static Methods

fromNextInvocation(NextInvocation nextInvocation) → dynamic
Creates a new Context from NextInvocation which is the data from the Lambda Runtime Interface for the next Handler<T> invocation.