Asyncmachine-go, declarative workflows with relations (state machine)
Asyncmachine-go, declarative workflows with relations (state machine)
Hi, I wrote a fancy state machine in golang and Im happy to share it with you (plus a cool video). Some readme quotes: asyncmachine-go is a general purpose state machine for managing complex asynchronous workflows in a safe and structured way Common differences with other state machines: - many states can be active at the same time - transitions between all the states are allowed - unless constrained - states are connected by relations - every mutation can be rejected - error is a state There are some bigger case studies and a benchmark using libp2p: - libp2p-pubsub benchmark (3 machines) - libp2p-pubsub simulator (5 machines) - am-dbg TUI debugger (1 machine) There's of course basic examples like FSM or a file watcher. The benchmark is especially interesting, eg the chart with execution time of the original libp2p-pubsub compared to the state-based version (measured using go1.22 traces), which is about 10-15%. That's a doable sacrifice for the benefits (states, events, thread-safety, logging, metrics, traces, debugger, history, flow constraints, scheduler). A good place to start is the readme and cookbook: https://github.com/pancsta/asyncmachine-go/blob/main/docs/co... Happy to answer all your questions!
Share cardActual performance
Launch Intel predictions
Analyze your own launch →Correct prediction on native model
Similar products
Finite State Machine for Go
Just state machine in ruby
State Trooper – Tiny, no frills state machine for Go
AsyncMachine – Relational State Machine (JS)
Tiny C++ State Machine Abstraction
I built an online state machine editor
Last System State Before OOM
A C++11 Hierarchical State Machine Library
State machine simulator written with Qt
Quorum-free replicated state machine built atop S3