windows workflow foundation mike taulty developer & platform group microsoft ltd...
TRANSCRIPT
![Page 1: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/1.jpg)
Windows Workflow FoundationWindows Workflow Foundation
Mike TaultyMike Taulty
Developer & Platform GroupDeveloper & Platform Group
Microsoft LtdMicrosoft Ltd
[email protected] [email protected]
http://mtaulty.com
![Page 2: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/2.jpg)
Intro: WinFXIntro: WinFX
![Page 3: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/3.jpg)
What’s WinFX?What’s WinFX?What’s WinFX?What’s WinFX?
Managed API for the Windows platformManaged API for the Windows platform
Extends the .NET Framework V2.0Extends the .NET Framework V2.0
First ships at the time of Windows Vista (2006)First ships at the time of Windows Vista (2006)
Included in Windows VistaIncluded in Windows Vista
Available on Windows XP Sp 2 and Server 2003Available on Windows XP Sp 2 and Server 2003
Following a Community Technology Preview CycleFollowing a Community Technology Preview Cycle
Latest is the February CTPLatest is the February CTP
![Page 4: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/4.jpg)
Intro: Windows Workflow FoundationIntro: Windows Workflow Foundation
![Page 5: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/5.jpg)
Windows Workflow FoundationWindows Workflow Foundation
Single Single frameworkframework for Workflow on Windows for Workflow on Windows
ExtensibleExtensible
Both human and system WorkflowBoth human and system Workflow
Supports long-running and stateful WorkflowsSupports long-running and stateful Workflows
![Page 6: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/6.jpg)
Activies – Workflow Building BlocksActivies – Workflow Building Blocks
Activities are classesActivities are classes
Basic Activities or Composite ActivitiesBasic Activities or Composite Activities
A A workflowworkflow is a composite activity is a composite activity
public string SourceFile;
public string DestFile;
override Execute()
{
File.Copy(SourceFile,
DestFile);
}
![Page 7: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/7.jpg)
Styles of WorkflowStyles of Workflow
![Page 8: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/8.jpg)
The Workflow FrameworkThe Workflow Framework(or “What’s in the box?”)(or “What’s in the box?”)
Runtime DesignerBase
Activities
Runtime
Services
![Page 9: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/9.jpg)
Framework:Framework: Workflow Runtime Workflow Runtime
![Page 10: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/10.jpg)
DemoDemo
Framework:Framework: Hosting the RuntimeHosting the Runtime
![Page 11: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/11.jpg)
Framework:Framework: Workflow Designer Workflow Designer
Hosted in Visual Studio 2005Hosted in Visual Studio 2005
Hosted in your application for end-usersHosted in your application for end-users
Supports theming in both VS and non-VS Supports theming in both VS and non-VS environmentsenvironments
![Page 12: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/12.jpg)
DemoDemo
Framework:Framework:Using/Hosting the DesignerUsing/Hosting the Designer
![Page 13: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/13.jpg)
Framework:Framework: Base Activity Library Base Activity Library
Pre-built set of building block activitiesPre-built set of building block activities
CompositeBasic
![Page 14: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/14.jpg)
DemoDemo
Framework:Framework:Using the Base Activity LibraryUsing the Base Activity Library
![Page 15: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/15.jpg)
Framework:Framework: Runtime Services Runtime Services
Runtime uses servicesRuntime uses services
PersistencePersistence
SchedulingScheduling
TrackingTracking
TransactionsTransactions
Defaults in the box for Defaults in the box for most servicesmost services
Pluggable – add your Pluggable – add your ownown
![Page 16: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/16.jpg)
DemoDemo
Framework:Framework:Plugging in Runtime ServicesPlugging in Runtime Services
![Page 17: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/17.jpg)
Building ActivitiesBuilding Activities
![Page 18: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/18.jpg)
Activities:Activities: Component Model Component Model
Activity is at the centre of a component modelActivity is at the centre of a component model
![Page 19: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/19.jpg)
Activities:Activities: Lifecycle Lifecycle
Activities have a lifecycleActivities have a lifecycle
![Page 20: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/20.jpg)
DemoDemo
Activities:Activities:Building custom activitiesBuilding custom activities
![Page 21: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/21.jpg)
Other things to know about…Other things to know about…
![Page 22: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/22.jpg)
Host/Workflow CommunicationHost/Workflow Communication
ILoanNotify{
GetLoanApproval();
event LoanApproved;
}
class Notifier
: ILoanNotify
{
}
![Page 23: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/23.jpg)
DemoDemo
Host/Workflow CommunicationHost/Workflow Communication
![Page 24: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/24.jpg)
State Machine WorkflowsState Machine Workflows
StateStart
Wait for X
Wait for Y
Wait for Z
State
State
Wait for A
Wait for B
Terminate
Activity
Activity
Transition
![Page 25: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/25.jpg)
DemoDemo
State Machine WorkflowsState Machine Workflows
![Page 26: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/26.jpg)
Applying Rule-Based PoliciesApplying Rule-Based Policies
Data
Policy (RuleSet)
Rule: If PRICE then
Rule: If … then
Rule: If … then
Rule: If … then
Rule: If … then
Priority: 1
Priority: 2
Priority: 3
Priority: 4
Priority: 5
Price: 200
Change
![Page 27: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/27.jpg)
DemoDemo
Rule based policiesRule based policies
![Page 28: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/28.jpg)
Transaction
Scope
Book Flight
Working with TransactionsWorking with TransactionsTransaction
Scope
Book Hotel
Error!
Commit happens here
Compensation
Cancel Hotel
![Page 29: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/29.jpg)
DemoDemo
Working with TransactionsWorking with Transactions
![Page 30: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/30.jpg)
Modifying Running InstancesModifying Running Instances
Running Workflow Running Workflow instance can be instance can be modifiedmodified
Logic changedLogic changed
Activities Activities added/removedadded/removed
Runtime managedRuntime managed
Change
![Page 31: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/31.jpg)
DemoDemo
Modifying Workflow InstancesModifying Workflow Instances
![Page 32: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/32.jpg)
ResourcesResources
MSDN Developer CentreMSDN Developer Centre
http://msdn.microsoft.com/winfxhttp://msdn.microsoft.com/winfx
Windows Workflow SiteWindows Workflow Site
http://www.windowsworkflow.nethttp://www.windowsworkflow.net
UK Community ResourcesUK Community Resources
http://www.roadtowinfx.comhttp://www.roadtowinfx.com
MSDN Nugget VideosMSDN Nugget Videos
http://www.msdn.co.uk/events/nuggets.aspxhttp://www.msdn.co.uk/events/nuggets.aspx
http://mtaulty.com/services/NuggetFeeds.ashx?query= topicshttp://mtaulty.com/services/NuggetFeeds.ashx?query= topics
![Page 33: Windows Workflow Foundation Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com](https://reader034.vdocuments.us/reader034/viewer/2022051416/56649ea25503460f94ba6b56/html5/thumbnails/33.jpg)
© 2006 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only.© 2006 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only.MICROSOFT MAKES NO WARRANTIES, EXPRESS OR IMPLIED, IN THIS SUMMARY.MICROSOFT MAKES NO WARRANTIES, EXPRESS OR IMPLIED, IN THIS SUMMARY.