1 / 22

Introducing Windows Workflow Foundation

Introducing Windows Workflow Foundation. Introducing Windows Workflow Foundation. Understanding Windows Workflow Foundation. Janakiram MSV Developer Evangelist Microsoft Corporation. Agenda. Architecture & Concepts Workflow Styles Summary. .Net Framework 3.0.

sanaa
Télécharger la présentation

Introducing Windows Workflow Foundation

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Introducing Windows Workflow Foundation

  2. Introducing Windows Workflow Foundation Understanding Windows Workflow Foundation Janakiram MSV Developer Evangelist Microsoft Corporation

  3. Agenda • Architecture & Concepts • Workflow Styles • Summary

  4. .Net Framework 3.0 • WPF-Windows Presentation Foundation • XAML • XAMLPad, Expression Editor, VS Designer • CardSpace • WCF-Windows Communication Foundation • WF-Workflow Foundation • Orcas • .NET 3.0 Visual Studio Extensions

  5. Power of Flow Chart • Maintainability is expensive • Code is opaque • Modules are hard-wired

  6. Flowchart Scenarios • Document Life Cycle Management • LOB Application Workflow • Business Process Management • UI Navigation Logic

  7. Yet Another Component…. public void PlaceNewOrder(Employee e, Product p) { if(e.FTE) switch(p.Category) { case “Computer”: if (GetManagerApproval(e,p)) { Inventory i=InventoryServiceProxy.GetInventory(P.ProductID); if(i.InStock) { PurchaseOrder PO=new PurchaseOrder(p,1); OrderAck Ack=OrderServiceProxy.SendPO(PO); SendMail( “Placed New Order”, ”Order #” + Ack.OrderNo+” Expected on ”+ ACK.ShipDate, e.EmailID ); } } ………………………………………………. ………………………………………………. }

  8. Today’s Application Development Rules and policies Forms Workflow model Application code Data Services Application logic

  9. What is Workflow? • Dictionary.com Definition • The flow or progress of work done by a company, industry, department, or person. • The rate at which such flow or progress takes place

  10. Tenets of Workflow Workflows coordinate work performed by peopleand by software Workflows are long running and stateful Workflows are based on extensible models Workflows are transparent and dynamic through their lifecycle

  11. Introducing Windows Workflow Foundation • Provide a singular engine for workflow execution for all applications built on the Windows platform • Supports a wide range of scenarios • Bring model-driven workflow development to the entire .NET development community • Enable reusable workflow component development to ensure both developers and ISVs can deeply embed this technology in their applications.

  12. Windows Workflow Foundation Visual Designer • Workflows are a set of Activities A Workflow • Workflows run within a Host Process:any application or server Key Concepts • Developers can build their own Custom Activity Libraries An Activity Custom Activity Library Components Windows Workflow Foundation • Base Activity Library:Out-of-box activities and base for custom activities Base Activity Library • Runtime Engine:Workflow execution and state management Runtime Engine • Runtime Services:Hosting flexibility and communication Runtime Services • Visual Designer: Graphical and code-based construction Host Process

  13. Workflow Basics using System.Workflow.Activities; public class Workflow1 : SequentialWorkflow { } • A workflow is a class • A workflow class may be defined in markup <?Mapping XmlNamespace="Activities" ClrNamespace="System.Workflow.Activities" Assembly="System.Workflow.Activities" ?> <SequentialWorkflow x:Class="MyWorkflow" xmlns="Activities" xmlns:x="Definition"> … </SequentialWorkflow>

  14. Workflow Basics using System.Workflow.Activities; public partial class Workflow1 : SequentialWorkflow { public Workflow1() { InitializeComponent(); } } public sealed partial class Workflow1 : SequentialWorkflow { private Delay delay1; private void InitializeComponent() { this.delay1 = new System.Workflow.Activities.Delay(); this.delay1.ID = “delay1"; this.delay1.TimeoutDuration = System.TimeSpan.Parse("00:00:05"); this.Activities.Add(this.delay1); this.ID = "Workflow1"; } } • Workflow constructor configures contained activities (like forms & controls)

  15. Demo Order Workflow

  16. Workflow Composition

  17. What are Activities? • An activity is a step in a workflow • Has propertiesandevents that are programmable within your workflow code • Has methods (e.g. Execute) that are only invoked by the workflow runtime • Think of Forms & Controls • Activity == Controls • Workflows == Forms • Activities fall under two broad categories • Basic – steps that “do work” • Composite – manage a set of child activities

  18. Domain-SpecificWorkflow Packages Compliance CRM Extend activity Compose activities RosettaNet Author new activity IT Mgmt • Vertical-specificactivities & workflows • Best-practice IP &Knowledge Activities: An Extensible Approach Custom ActivityLibraries Base Activity Library Base Activity Library • OOB activities,workflow types,base types • General-purpose • Activity libraries define workflow constructs • Create/Extend/Compose activities • App-specificbuilding blocks • First-class citizens

  19. Flexible Control Flow State1 State2 State Machine Workflow Sequential Workflow External events drive processing order Sequential structure prescribes processing order Step1 Event Step2 Event • Prescriptive, formal • Automation scenarios • Flowchart metaphor • Reactive, event-driven • Skip/re-work, exception handling • Graph metaphor Rules-driven Activities Rule1 Step1 Rules + data state drive processing order Data Step2 Rule2 • Data-driven • Simple Conditions, complex Policies • Constrained Activity Group

  20. Summary • A single workflow technology for Windows • Platform level workflow framework for use within Microsoft products & ISV applications • Will be used by BizTalk Server, Office 2007 MBS & other Microsoft client/server products • Available to all Windows customers • Microsoft is redefining workflow • Unified technology for System & Human workflow • Multiple styles: sequential, rules-based, state machine • Supports dynamic interaction • Microsoft is taking workflow mainstream • Consistent and familiar programming model for reaching mainstream application developer • Available to millions of end-users through Office 2007 • Extensible platform for ISVs

  21. Resources • http://wf.netfx3.com • http://msdn.microsoft.com/winfx • http://www.microsoft.com/seminar Janakiram.msv@microsoft.com

  22. QuestionsMicrosoft Windows Vistawww.microsoft.com/windowsvista/

More Related