For those of you working with Step Functions, what...
# general
s
For those of you working with Step Functions, what is your process for capturing the workflow in IaC?
The workflow editor is fantastic, and I've been able to build some workflows/state machines pretty easily
I suspect the process is 1. build what you want in the workflow editor 2. test/validate the workflow 3. manually write IaC to reproduce what you've built
Is there a better way?
m
I find just hacking it out in CDK to be good enough. I've used the workflow editor a little just to get the creative juices flowing, but haven't actually used it to save a state machine and execute it.
s
@Seth Geoghegan Instead of manually writing it out, you can copy the ASL from the workflow studio and use the CDK StateMachine construct to integrate your asl with the services created by your CDK stack.
This idea is from Matthew Bonig. You can read more about it in his blog. https://matthewbonig.com/2022/02/19/step-functions-and-the-cdk/
m
I've seen that, but I find working with the constructs fairly decent. My only complaint is that they don't necessarily format well. I think it kind of depends on the paradigm you're used to.