Skip to content

Latest commit

 

History

History
64 lines (47 loc) · 9.44 KB

lambda-properties.md

File metadata and controls

64 lines (47 loc) · 9.44 KB

Environment Variables applicable for Lambda Functions

Following are the properties that are applicable for HeartBeat, APIs, and Metrics Lambda Functions.

Amazon API Gateway configurations let you specify Amazon API Gateway configurations required for AWS connectivity.

Properties Description
AWS_STAGE Mandatory. Stage (Runtime) name in Amazon API Gateway.

Agent configurations let you specify the Agent configurations such as heart beat interval, assets sync interval, metrics sync interval, and so on.

Properties Description Possible Values
APICP_HEARTBEAT_SEND_INTERVAL_SECONDS Optional. The duration in seconds in which the Agent must send the health check status to API Control Plane. Min: 15 seconds
Max: 900 seconds (5 minutes).
Default: 60 seconds

If you do not specify a value for this property, the default value is considered.

Runtime configurations lets you specify the metadata of Amazon Gateway that you want to administer from the API Control Plane such as Runtime name, Description, Tags, and so on.

Properties Description
APICP_RUNTIME_NAME Mandatory. The runtime name.
This property defines how you want to identify the runtime in API Control Plane.
Name must not exceed 50 characters.

When the runtime gets registered with API Control Plane for the first time, the current implementation generates the runtime ID in the format <AWS_account_ID><AWS_region><AWS_stage>. As a result, changing the runtime name does not alter the runtime ID.
Even if the runtime name is changed between agent restarts, a new runtime does not get created in API Control Plane. Instead, the runtime name gets updated for the existing runtime.
APICP_RUNTIME_DESCRIPTION Optional. The runtime description.
Description must not exceed 300 characters.
Default value: AWS Runtime. If you do not specify a value for this property, the default value is considered.
APICP_RUNTIME_REGION Mandatory. The region name where the runtime is hosted.
Example: EAST US
Region name must not exceed 50 characters.
APICP_RUNTIME_LOCATION Optional. The location where the runtime is deployed.
Example: DENVER
Location name can not be empty and must not exceed 50 characters.
APICP_RUNTIME_TAGS Optional. The tag name of the runtime.
Default: aws
If you do not specify a value for this property, the default value is considered.
Tags are used to organize and categorize the runtimes. Multiple tags can be specified by adding comma.
Example: test, local, dev
Tags must not exceed 50 characters. It must not contain whitespaces and the number of tags must not exceed 100.
APICP_RUNTIME_CAPACITY_VALUE Optional. The number of transaction calls that a runtime can process for the specified duration. You can configure the capacity value with any non-negative integer
Default value: 500000
APICP_RUNTIME_CAPACITY_UNIT Optional. You can configure the capacity value with any non-negative integer and for any duration which can be in the following units:
  • PER_SECOND
  • PER_MINUTE
  • PER_HOUR
  • PER_DAY
  • PER_WEEK
  • PER_MONTH
  • PER_YEAR (Default value)

If you do not specify a value for this property, the default value is considered.
APICP_RUNTIME_TYPE_ID Mandatory. The Id of the runtime type.
Pre-defined types: WEBMETHODS_DEVELOPER_PORTAL, WEBMETHODS_API_GATEWAY
Ensure to verify if the runtime type exists in API Control Plane. If it does not exist, use the Runtime Type Management Service REST API to add the runtime type. For details, see How to create the runtime type?

API Control Plane configurations let you specify API Control Plane details to which Amazon API Gateway must establish the connectivity.

Properties Description
APICP_URL Mandatory. The valid URL that is used to access API Control Plane.
APICP_USERNAME Mandatory. User name that is used to log in to API Control Plane.
APICP_PASSWORD Mandatory. Password of the corresponding user name, which is used for logging into the API Control Plane through basic authentication.
APICP_SSL_ENABLED Optional. The SSL certification of API Control Plane.
Possible values: true or false
APICP_TRUSTSTORE_PATH Optional. Location of the truststore file.
If APICP_SSL_ENABLED is set to true, you must specify a value for this property.
APICP_TRUSTSTORE_PASSWORD Optional. Password to access the truststore file.
If APICP_SSL_ENABLED is set to true, you must specify a value for this property.
APICP_TRUSTSTORE_TYPE Optional. Type of the truststore.
If APICP_SSL_ENABLED is set to true, you must specify a value for this property.
APICP_KEYSTORE_PATH Optional. Location of the keystore file.
If APICP_SSL_ENABLED is set to true, you must specify a value for this property.
APICP_KEYSTORE_PASSWORD Optional. Password to access the keystore file.
If APICP_SSL_ENABLED is set to true, you must specify a value for this property.
APICP_KEYSTORE_TYPE Optional. Type of the keystore.
If APICP_SSL_ENABLED is set to true, you must specify a value for this property.
APICP_KEY_ALIAS Optional. Alias of key in the keystore.
If APICP_SSL_ENABLED is set to true, you must specify a value for this property.
APICP_KEY_PASSWORD Optional. Password of key in the keystore.
If APICP_SSL_ENABLED is set to true, you must specify a value for this property.

Following are the properties that are specific to Metrics Lambda Function.

Properties Description
AWS_METRICS_BY_DATA_OR_STATISTICS Optional. Method in which the metrics are retrieved from CloudWatch.
Values:
  • Data
  • Statistics

The default value is Statistics. If you do not specify a value for this property, the default value is considered.
AWS_METRICS_SYNC_BUFFER_INTERVAL_SECONDS Optional. By default, Amazon API Gateway metric data is automatically sent to Amazon CloudWatch in one-minute interval. That is, most Amazon API Gateway metrics will be available in Amazon CloudWatch within 1 minute of the original data point.

But to ensure proper metrics sync, set CloudWatch buffer time interval as more than 600 seconds (10 minutes).
The default value is 600 seconds. If you do not specify a value for this property, the default value is considered.
APICP_METRICS_SEND_INTERVAL_SECONDS Optional. The duration in seconds in which the Agent must retrieve the metrics from Amazon CloudWatch and send metrics to API Control Plane.

Supported metric synchronization values:
  • 60 seconds (1 minute)(Default value)
  • 300 seconds (5 minutes)
  • 600 seconds (10 minutes)
  • 1800 seconds (30 minutes)
  • 3600 seconds (60 minutes)
  • 7200 seconds (120 minutes)


If you do not specify a value for this property, the default value is considered.

Following are the properties that are specific to Assets Lambda Function.

Properties Description
APICP_ASSETS_SYNC_INTERVAL_SECONDS Optional. The duration in seconds in which the Agent must synchronize the changes made to the assets from the Amazon CloudTrail to API Control Plane.

Min:60 seconds
Max: 21600 seconds (6 hours).
Default: 300 seconds

If you do not specify a value for this property, the default value is considered.
AWS_ASSETS_SYNC_BUFFER_INTERVAL_SECONDS Mandatory. CloudTrail typically delivers API Gateway management events within about 5 minutes of the API call being made. This is the standard delivery time for CloudTrail events.

Therefore, set CloudTrail event time interval as more than 300 seconds (5 minutes).
The default value is 300 seconds. If you do not specify a value for this property, the default value is considered.