4. Advanced Activity Execution

IN THE PREVIOUS CHAPTER, we learned about the basic lifecycle of an activity, which involves the Initialized, Executing, and Closed states of the activity automaton. We also explored the ramifications of the fact that the logical lifetime of activities differs from the lifetimes of CLR objects that transiently represent activities during those times that a WF program instance is not passivated. We developed several useful activities, including a few composite activities, and illustrated the central role of the ActivityExecutionContext as a facilitator of activity execution.

In this chapter, we will give more scrutiny to ActivityExecutionContext and introduce its vital role as a state boundary in WF programs. This ...

Get Essential Windows Workflow Foundation now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.