7. "I want to sequence functions"
"I want to select functions based on data"
"I want to retry functions"
"I want try/catch/finally"
Functions into apps
"I have code that runs for hours"
"I want to run functions in parallel"
12. Application Lifecycle in AWS Step Functions
Visualize in the
Console
Define in JSON Monitor
Executions
13. Define in JSON and Then Visualize in the Console
{
"Comment": "Hello World Example",
"StartAt" : "HelloWorld",
"States" : {
"HelloWorld" : {
"Type" : "Task",
"Resource" : "${lambdaArn}",
"End" : true
}
}
}
14. Execute One or One Million
Start
End
HelloWorld
Start
End
HelloWorld
Start
End
HelloWorld
Start
End
HelloWorld
Start
End
HelloWorld
Start
End
HelloWorld
Start
End
HelloWorld
Start
End
HelloWorld
17. Seven State Types
Task A single unit of work
Choice Adds branching logic
Parallel Fork and join the data across tasks
Wait Delay for a specified time
Fail Stops an execution and marks it as a failure
Succeed Stops an execution successfully
Pass Passes its input to its output
26. Amazon EBS Snapshot Management
State Machine State Machine
create-snapshot
complete event
copy-snapshot
complete event
Primary Region DR Region
Parallel State
Choice
Tag Snapshot
Count Snapshots
CopyToDRRegion
Success
State
Delete
Snapshots
Choice
Tag SnapshotCopy
Count Snapshots
Pass State
Delete
Snapshots
Notification
Topic
Errors Sent
to SNS
Notification
Topic
Errors Sent
to SNS
https://github.com/awslabs/aws-step-functions-ebs-snapshot-mgmt
1. Tag
2. Count
3. Copy to DR region
4. Delete Expired
Whenever a new EBS
snapshot completes:
State Machines
invoked by Amazon
CloudWatch Events