- 최신
- 최다 투표
- 가장 많은 댓글
You can specify a specific lambda function version or alias by providing a qualified function ARN in the detector model definition. An unqualified ARN will call the $LATEST version.
You can see more on qualified and unqualified function ARN here:
https://docs.aws.amazon.com/lambda/latest/dg/configuration-versions.html
Thanks for the reply!
When I'm using the Events model editor, I believe it currently only lets me specify a lambda action, it only lets me specify the lambda by name, not ARN. Right?
And currently, it doesn't let me specify the name with 'my-lambda:3' or 'my-lambda:devel'.
One way or another, it would be handy to specify the specific version/alias to call. Does that seem reasonable?
The console does not support adding versions yet. For now you can set version in function ARN in detector model definition through CLI. We are working on adding this feature to console.
Example in adding versions:
You can add version to Lambda function ARN like the example below, and then update your detector model through update-detector-model command
{
"lambda": {
"functionArn": "arn:aws:lambda:<REGION>:<YOUR_ACCOUNT_ID>:function:<FUNCTION_NAME>:<VERSION>"
}
}
You can check full detector model definition in attachment
For more info regarding update-detector-model command, please visit https://docs.aws.amazon.com/iotevents/latest/developerguide/iotevents-commands.html
you can create function aliases. please see https://docs.aws.amazon.com/lambda/latest/dg/configuration-aliases.html