Tuesday 12 February 2008

Windows Workflow Foundation

Windows Workflow Foundation is a part of the .NET Framework 3.0 (and 3.5) that enables developers to create workflow enabled applications. It consists of the following parts:

Activity Model: Activities are the building blocks of workflow, think of them as a unit of work that needs to be executed. Activities are easy to create, either from writing code or by composing them from other activities. Out of the box, there are a set of activities provided that mainly provide structure, such as parallel execution, if/else, call web service.

Workflow Designer: This is the design surface that you see within Visual Studio, and it allows for the graphical composition of workflows, by placing activities within the workflow model. You can find a screenshot of designing a sequential workflow here. One interesting feature of the designer is that it can be re-hosted within any Windows Forms application. Check out this article on MSDN to see how you can do this. http://wf.netfx3.com/files/folders/design_time/entry1923.aspx

Workflow Runtime: Our runtime is a light-weight and extensible engine that executes the activites which make up a workflow. The runtime is hosted within any .NET process, enabling developers to bring workflow to anything from a Windows Forms application to an ASP.NET web site or a Windows Service.

Rules Engine: Windows Workflow Foundation has a rules engine which enables declarative, rule-based development for workflows and any .NET application to use.

Here is an article which outlines the capabilities of the rules engine. http://msdn2.microsoft.com/en-us/library/aa480193.aspx

Windows Workflow Foundation will be released as part of the .NET Framework 3.0 which is part of the Windows Vista release. The .NET Framework 3.0 will be available for Windows XP as well as Windows Server 2003. In the .NET Framework 3.5, WF receives an additive update in the form of integration with Windows Communication Foundation

Source: http://netfx3.com/content/WFHome.aspx

Great code example: http://community.bartdesmet.net/blogs/bart/archive/2006/08/27/4278.aspx

No comments: