Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can a lambda in an AWS Step Function know its current Execution Id of AWS Step Function?

For a lambda executed within a step function, I want to know the current execution id of AWS State Machine within that. Is there a way to know this within the step function?

like image 542
ajay0221 Avatar asked May 08 '18 10:05

ajay0221


1 Answers

Old question but the answer is outdated - you can now get this inside the step function - with $$.Execution.id. Example I'm using:

"run_task": {
  "Type": "Task",
  "Parameters": {
    "task.$": "$.task",
    "executionId.$": "$$.Execution.Id"
  },
  "Resource": "${runTaskLambdaArn}",
  "End": true
}
like image 143
Callum M Avatar answered Oct 08 '22 06:10

Callum M