Skip to content

LambdaExecutionParameters

Source code in docs_src/capo_greengrassv2/types/lambda_execution_parameters.py
class LambdaExecutionParameters(TypedDict, closed=True):
    event_sources: NotRequired[
        "capo_greengrassv2.types.lambda_event_source_list.LambdaEventSourceList"
    ]
    """<p>The list of event sources to which to subscribe to receive work messages. The Lambda function runs when it receives a message from an event source. You can subscribe this function to local publish/subscribe messages and Amazon Web Services IoT Core MQTT messages.</p>"""
    max_queue_size: NotRequired[
        "capo_greengrassv2.types.optional_integer.OptionalInteger"
    ]
    """<p>The maximum size of the message queue for the Lambda function component. The IoT Greengrass core stores messages in a FIFO (first-in-first-out) queue until it can run the Lambda function to consume each message.</p>"""
    max_instances_count: NotRequired[
        "capo_greengrassv2.types.optional_integer.OptionalInteger"
    ]
    """<p>The maximum number of instances that a non-pinned Lambda function can run at the same time.</p>"""
    max_idle_time_in_seconds: NotRequired[
        "capo_greengrassv2.types.optional_integer.OptionalInteger"
    ]
    """<p>The maximum amount of time in seconds that a non-pinned Lambda function can idle before the IoT Greengrass Core software stops its process.</p>"""
    timeout_in_seconds: NotRequired[
        "capo_greengrassv2.types.optional_integer.OptionalInteger"
    ]
    """<p>The maximum amount of time in seconds that the Lambda function can process a work item.</p>"""
    status_timeout_in_seconds: NotRequired[
        "capo_greengrassv2.types.optional_integer.OptionalInteger"
    ]
    """<p>The interval in seconds at which a pinned (also known as long-lived) Lambda function component sends status updates to the Lambda manager component.</p>"""
    pinned: NotRequired["capo_greengrassv2.types.optional_boolean.OptionalBoolean"]
    """<p>Whether or not the Lambda function is pinned, or long-lived.</p> <ul> <li> <p>A pinned Lambda function starts when IoT Greengrass starts and keeps running in its own container.</p> </li> <li> <p>A non-pinned Lambda function starts only when it receives a work item and exists after it idles for <code>maxIdleTimeInSeconds</code>. If the function has multiple work items, the IoT Greengrass Core software creates multiple instances of the function.</p> </li> </ul> <p>Default: <code>true</code> </p>"""
    input_payload_encoding_type: NotRequired[
        "capo_greengrassv2.types.lambda_input_payload_encoding_type.LambdaInputPayloadEncodingType"
    ]
    """<p>The encoding type that the Lambda function supports.</p> <p>Default: <code>json</code> </p>"""
    exec_args: NotRequired[
        "capo_greengrassv2.types.lambda_exec_args_list.LambdaExecArgsList"
    ]
    """<p>The list of arguments to pass to the Lambda function when it runs.</p>"""
    environment_variables: NotRequired[
        "capo_greengrassv2.types.lambda_environment_variables.LambdaEnvironmentVariables"
    ]
    """<p>The map of environment variables that are available to the Lambda function when it runs.</p>"""
    linux_process_params: NotRequired[
        "capo_greengrassv2.types.lambda_linux_process_params.LambdaLinuxProcessParams"
    ]
    """<p>The parameters for the Linux process that contains the Lambda function.</p>"""

environment_variables instance-attribute

environment_variables: NotRequired[LambdaEnvironmentVariables]

The map of environment variables that are available to the Lambda function when it runs.

event_sources instance-attribute

event_sources: NotRequired[LambdaEventSourceList]

The list of event sources to which to subscribe to receive work messages. The Lambda function runs when it receives a message from an event source. You can subscribe this function to local publish/subscribe messages and Amazon Web Services IoT Core MQTT messages.

exec_args instance-attribute

exec_args: NotRequired[LambdaExecArgsList]

The list of arguments to pass to the Lambda function when it runs.

input_payload_encoding_type instance-attribute

input_payload_encoding_type: NotRequired[LambdaInputPayloadEncodingType]

The encoding type that the Lambda function supports.

Default: json

linux_process_params instance-attribute

linux_process_params: NotRequired[LambdaLinuxProcessParams]

The parameters for the Linux process that contains the Lambda function.

max_idle_time_in_seconds instance-attribute

max_idle_time_in_seconds: NotRequired[OptionalInteger]

The maximum amount of time in seconds that a non-pinned Lambda function can idle before the IoT Greengrass Core software stops its process.

max_instances_count instance-attribute

max_instances_count: NotRequired[OptionalInteger]

The maximum number of instances that a non-pinned Lambda function can run at the same time.

max_queue_size instance-attribute

max_queue_size: NotRequired[OptionalInteger]

The maximum size of the message queue for the Lambda function component. The IoT Greengrass core stores messages in a FIFO (first-in-first-out) queue until it can run the Lambda function to consume each message.

pinned instance-attribute

pinned: NotRequired[OptionalBoolean]

Whether or not the Lambda function is pinned, or long-lived.

  • A pinned Lambda function starts when IoT Greengrass starts and keeps running in its own container.

  • A non-pinned Lambda function starts only when it receives a work item and exists after it idles for maxIdleTimeInSeconds. If the function has multiple work items, the IoT Greengrass Core software creates multiple instances of the function.

Default: true

status_timeout_in_seconds instance-attribute

status_timeout_in_seconds: NotRequired[OptionalInteger]

The interval in seconds at which a pinned (also known as long-lived) Lambda function component sends status updates to the Lambda manager component.

timeout_in_seconds instance-attribute

timeout_in_seconds: NotRequired[OptionalInteger]

The maximum amount of time in seconds that the Lambda function can process a work item.