Files
mediaproc/ctrl/state-machine.json

40 lines
875 B
JSON

{
"Comment": "MPR Transcode Job - orchestrates Lambda-based media transcoding",
"StartAt": "Transcode",
"States": {
"Transcode": {
"Type": "Task",
"Resource": "${TranscodeLambdaArn}",
"TimeoutSeconds": 900,
"Retry": [
{
"ErrorEquals": ["States.TaskFailed", "Lambda.ServiceException"],
"IntervalSeconds": 10,
"MaxAttempts": 2,
"BackoffRate": 2.0
}
],
"Catch": [
{
"ErrorEquals": ["States.ALL"],
"Next": "HandleError",
"ResultPath": "$.error"
}
],
"Next": "Done"
},
"HandleError": {
"Type": "Pass",
"Parameters": {
"status": "failed",
"job_id.$": "$.job_id",
"error.$": "$.error.Cause"
},
"Next": "Done"
},
"Done": {
"Type": "Succeed"
}
}
}