AWS Lambda Connector 1.0.0.0
The AWS Lambda Connector lets you invoke AWS Lambda functions synchronously or asynchronously,
Prerequisites
- RunMyJobs 9.2.9 or higher.
- Connection Management Extension 1.0.0.5 or later. This will be installed or updated automatically if necessary when you install the AWS Lambda Connector.
- AWS Utilities 1.0.0.1 or later. This will be installed or updated automatically if necessary when you install the AWS Lambda Connector.
- An AWS Connection.
- Privileges Required to Use the AWS Lambda Connector.
Contents
Object Type | Name | Description |
---|---|---|
Folder | GLOBAL.Redwood.REDWOOD.AWS.REDWOOD.Lambda | Integration Connector with AWS Lambda (1.0.0.0) |
Constraint Definition | REDWOOD.Redwood_AWS_LambdaConstraint | Constraint for AWS Lambda function in the specified region |
Job Definition | REDWOOD.Redwood_AWS_Lambda_InvokeFunction_Template | Template for Invoke AWS Lambda Function |
Job Definition Type | REDWOOD.Redwood_AWS_Lambda | AWS Lambda Definition Type |
Library | REDWOOD.Redwood_AWS_Lambda | Library for AWS Lambda Connector |
Setup
To install the AWS Lambda Connector, click its tile in the Catalog, select the version you want, and then click Install <version number>.
Job Definitions
Redwood_AWS_Lambda_InvokeFunction_Template
Template for invoking AWS Lambda functions.
Parameters
Tab | Name | Description | Documentation | Data Type | Direction | Default Expression | Values |
---|---|---|---|---|---|---|---|
Parameters | connection
|
AWS Lambda Connection | The AWS Connection to use for invoking the Lambda function. | String | In |
|
|
Parameters | regionName
|
Region | The name of the Region that the AWS Lambda is located in. | String | In |
|
|
Parameters | functionName
|
Function Name | Name of the Lambda function to invoke. | String | In |
|
|
Parameters | waitForCompletion
|
Wait for Completion |
If you enter Note: If you set this field to No (asynchronous execution), any Note: If you set this field to Yes (synchronous execution), the last 4KB of the Lambda log is written to the |
String | In | No
|
Yes , No |
Parameters | requestId
|
Request Id | The ID of the invocation request. | String | Out |
|
|
Parameters | response
|
Response Output | Link to the generated response.json file that contains the output of the Job. |
String | Out |
|
|
Procedures
Triggering a Lambda Function with a Template
To create a customized Job Definition, optionally with default values, for triggering a Lambda function:
-
Right-click the Redwood_AWS_Lambda_InvokeFunction_Template Job Definition and choose New (from Template) from the context menu. The New Job Definition tab displays.
-
Choose a Partition.
-
Enter a Name.
-
Delete the default Folder value (if any) and substitute your own Folder name if desired.
-
In the Source field, the default content is this:
Copy{
"clientContext": {},
"payload": {
}
}You can use this JSON to pass Parameter values to AWS Lambda. For example, if you create Parameters for the values your AWS Lambda requires, you can then set the Source field to something like this:
Copy{
"clientContext": {
"client": {
"app_package_name": "${appPackageName}",
"app_title": "${myApp}",
"app_version_code": "${app_version_code}",
"app_version_name": "${app_version_name}"
},
"env": {
"platform": "${platform}",
"platform_version": "${platform_version}",
"make": "${make}",
"model": "${model}",
"key1": "${key1}"
},
"custom": {
"user_id": "${user_id}",
"session_id": "${session_id}",
"key1": "${key1}"
}},
"payload": {
"client": {
"app_package_name": "${appPackageName}",
"app_title": "${myApp}",
"app_version_code": "${app_version_code}",
"app_version_name": "${app_version_name}"
},
"env": {
"platform": "${platform}",
"platform_version": "${platform_version}",
"make": "${make}",
"model": "${model}",
"key1": "${key1}"
},
"custom": {
"user_id": "${user_id}",
"session_id": "${session_id}",
"key1": "${key1}"
}}
} -
In the Parameters tab, create any desired Parameters and enter any Default Expressions you want to use.
-
When specifying the Connection value, use the format
EXTCONNECTION:<partition>.<connection name>
. -
Save and then submit the new Job Definition.