func (w *WorkerFSM) One() fsm.Decider { return fsm.NewComposedDecider( fsm.OnActivityFailedTimedOutCanceled("one", fsm.AddDecision(w.actOne)), fsm.OnActivityCompleted("one", fsm.UpdateState(w.afterOne), fsm.AddDecision(w.actTwo), fsm.Transition("Two"), ), ) }
func (w *WorkerFSM) Initial() fsm.Decider { return fsm.OnStarted( fsm.AddDecision(w.actOne), fsm.Transition("One"), ) }