When WaitForCondition runs, the workflow system checks the system for a work item that matches the specified criteria. If no existing work item meets the condition, the waiting work item is moved to the Delay system queue.
Newly created work items |
Every newly created work item is checked for the condition. |
---|---|
Work items as they enter queues |
Every time that a work item enters a queue, the condition is checked. Therefore, it is possible for a work item that did not meet the match criteria when WaitForCondition ran to change during processing so that it later meets the match criteria. |
Terminating work items |
All terminated work items are checked for the condition. These items include both normally terminated items and manually terminated items. An item might be manually terminated in the administration console or some other tool. Manually deleted items are not checked for the condition. |
Checking continues until a match is found or until the specified timeout period expires. If multiple work items meet the match criteria, the work item with the oldest date/time stamp satisfies the wait condition. A single work item can satisfy multiple waiting work items; a work item has no knowledge of being waited for.
After these actions occur, processing for both (waiting and waited-for) work items continues as specified on their workflow maps.