Skip to main content

function_definition_versions

Creates, updates, deletes, gets or lists a function_definition_versions resource.

Overview

Namefunction_definition_versions
TypeResource
Idaws.greengrass.function_definition_versions

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
arnstringThe ARN of the function definition version.
creation_timestampstringThe time, in milliseconds since the epoch, when the function definition version was created.
definitionobjectInformation about a function definition version.
idstringThe ID of the function definition version.
next_tokenstringThe token for the next set of results, or ''null'' if there are no additional results.
versionstringThe version of the function definition version.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_function_definition_versionselectfunction_definition_id, function_definition_version_id, regionNextTokenRetrieves information about a Lambda function definition version, including which Lambda functions are included in the version and their configurations.
list_function_definition_versionsselectfunction_definition_id, regionMaxResults, NextTokenLists the versions of a Lambda function definition.
create_function_definition_versioninsertfunction_definition_id, regionX-Amzn-Client-TokenCreates a version of a Lambda function definition that has already been defined.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
function_definition_idstringThe ID of the Lambda function definition.
function_definition_version_idstringThe ID of the function definition version. This value maps to the ''Version'' property of the corresponding ''VersionInformation'' object, which is returned by ''ListFunctionDefinitionVersions'' requests. If the version is the last one that was associated with a function definition, the value also maps to the ''LatestVersion'' property of the corresponding ''DefinitionInformation'' object.
regionstringAWS region (default: us-east-1)
MaxResultsstringThe maximum number of results to be returned per request.
NextTokenstringThe token for the next set of results, or ''null'' if there are no additional results.
X-Amzn-Client-TokenstringA client token used to correlate requests and responses.

SELECT examples

Retrieves information about a Lambda function definition version, including which Lambda functions are included in the version and their configurations.

SELECT
arn,
creation_timestamp,
definition,
id,
next_token,
version
FROM aws.greengrass.function_definition_versions
WHERE function_definition_id = '{{ function_definition_id }}' -- required
AND function_definition_version_id = '{{ function_definition_version_id }}' -- required
AND region = '{{ region }}' -- required
AND NextToken = '{{ NextToken }}'
;

INSERT examples

Creates a version of a Lambda function definition that has already been defined.

INSERT INTO aws.greengrass.function_definition_versions (
DefaultConfig,
Functions,
function_definition_id,
region,
`X-Amzn-Client-Token`
)
SELECT
'{{ DefaultConfig }}',
'{{ Functions }}',
'{{ function_definition_id }}',
'{{ region }}',
'{{ X-Amzn-Client-Token }}'
RETURNING
arn,
creation_timestamp,
id,
version
;