While working on a project, I realized that I needed a state machine which operates on a web server. I also realized that I was too cheap to upgrade my shared server to a virtual server. Thus, I was stuck with CGI, which begins execution when a request is received, and halts when the response has been sent. No data, e.g. state, can be saved between requests.
I researched previous state machines. All but one were intended for continuous execution. The other one was part of a much larger library, not free, and far more complicated than I needed. In addition, I noted that all were structured as a generator to build the state machine, which is then executed. I further noted that the generators expected data specifying the state machine in different places: state names in one place, transitions in another, and state functions in another. ... read more