2 個答案
- 最新
- 最多得票
- 最多評論
2
It seems it is not shown in the context object. I will raise it with the service team.
1
Hi,
The way to obtain the version of a state machine is to use API DescribeStateMachine
in the Step AWS SDK of your favorite language : https://docs.aws.amazon.com/step-functions/latest/apireference/API_DescribeStateMachine.html
It's called revisionId in the returned Json:
{
"creationDate": number,
"definition": "string",
"description": "string",
"label": "string",
"loggingConfiguration": {
"destinations": [
{
"cloudWatchLogsLogGroup": {
"logGroupArn": "string"
}
}
],
"includeExecutionData": boolean,
"level": "string"
},
"name": "string",
"revisionId": "string",
"roleArn": "string",
"stateMachineArn": "string",
"status": "string",
"tracingConfiguration": {
"enabled": boolean
},
"type": "string"
}
Best,
Didier
相關內容
- AWS 官方已更新 1 年前
BTW, why do you need it?
In the meantime, you can use DescribeExceution or GetExecutionHistory to get the information.
I'm looking at doing a consistency check between the version of the Step Function that's running and the version of the Lambdas it's executing, and if the Step Function included this in context as Lambda does then this would be a convenient and performant way to do it