A simple state machine representing the state of a two-phase commit, as well as providing next steps to be taken in the case of a coordinator recovery after a crash.