We have been debugging a situation where a workflow step failed. This rule has a mix of long running and short running tasks, ranging from a Get Metadata task at 33 ms to a SQL update at 1 sec 500 ms. As we looked at the actual task details we noticed that some of our early tasks were not finished before some of the later tasks had begun. Here is a simplified example:
Task A: Starts at 7:15:10 AM, ends at 7:15:12 AM
Task B: Starts at 7:15:11 AM, ends at 7:15:11 AM
Task B started before Task A was finished.
In another case, we had a task that posts a row, and then a task right after that reads it. The second task failed (no results) yet the row was present when we checked.
I assumed each rule instance has its own thread, but it also looks like each task has its own thread. However, in a linear product like Workflow, it's hard to see how it would work unless is is sequential. So, is this just an issue with the reporting, or should we be adding a delay after each long running task?
It feels very quantum...