ballerinax/awslambda module

Module Detail

Objects

Object Description
Context

Object to represent an AWS Lambda function execution context.

Functions

Function Description
__process
__register

Annotations

Name Attaches To Data Type Description
Function function -

@awslambda:Function annotation

public function __process()

public function __register(string handler, function (awslambda:Context,json) returns (json|error) func)

Parameter Name Data Type Default Value Description
handler string
func function (awslambda:Context,json) returns (json|error)

public type Context object

Object to represent an AWS Lambda function execution context.

  • <Context> getRequestId() returns (string)

    Returns the unique id for this request.

    Return Type Description
    string

    the request id

  • <Context> getDeadlineMs() returns (int)

    Returns the request execution deadline in milliseconds from the epoch.

    Return Type Description
    int

    the request execution deadline

  • <Context> getInvokedFunctionArn() returns (string)

    Returns the ARN of the function being invoked.

    Return Type Description
    string

    the invoked function ARN

  • <Context> getTraceId() returns (string)

    Returns the trace id for this request

    Return Type Description
    string

    the trace id

  • <Context> getRemainingExecutionTime() returns (int)

    Returns the remaining execution time for this request in milliseconds

    Return Type Description
    int

    the remaining execution time