Hello,
I've got an async. state machine (1.44, MSVC10), and sometimes I
observe a very strange behavior: events being processed not in the
order they are queued. I spent some time trying to investigate this
issue, but due to the asynchronous nature of the processing, it's
quite not trivial. So, before I start sinking too deep, I'd like to
ensure I don't miss something trivial.
Unfortunately, I don't have at the moment any self-contained code, but
a very simplified model of my FSM is as follows. Assume there are 2
events: Ev1, Ev2. The both are queued to the FMS from the same thread,
always in the same order: Ev1, Ev2. The FSM processes them in another
thread.
The FMS has some "entry" chain of states that defer the both events:
S1 /[defer(Ev1, Ev2)] --> S2 /[defer(Ev1, Ev2)]
and finally 2 orthogonal sub-states, one of them ignores the both
events, and the other processes the both:
...S2 --> S3