41
Spice Up Your Applications with WF 4 Matt Winkler Program Manager [email protected] http://blogs.msdn.com/mwinkle FT17

Spice Up Your Applications with WF 4

  • Upload
    allie

  • View
    30

  • Download
    0

Embed Size (px)

DESCRIPTION

FT17. Spice Up Your Applications with WF 4 . M att Winkler P rogram Manager [email protected] http://blogs.msdn.com/mwinkle. Where This Talk Fits. Visual Studio. IIS Management. Activities. PowerShell. Application Host. WCF Runtime. WF Runtime. Persistence. Monitoring. - PowerPoint PPT Presentation

Citation preview

Page 1: Spice Up Your Applications  with WF 4

Spice Up Your Applications with WF 4

Matt WinklerProgram Manager

[email protected]://blogs.msdn.com/mwinkle

FT17

Page 2: Spice Up Your Applications  with WF 4

Where This Talk Fits

Process Host

Application Host

Visual Studio

Activities

IIS Management

PowerShell

WFRuntime

MonitoringPersistence

StorageWCF

Runtime

Page 3: Spice Up Your Applications  with WF 4

WF in 3 minutes or less> WF is three things

> Activities> Runtime> Tooling

> To use WF in your app> Build activities> Create workflows which use those

activities> Let the runtime deal with running the

activities

Page 4: Spice Up Your Applications  with WF 4

Embedded Process Engine

Page 5: Spice Up Your Applications  with WF 4

Embedded Process Engine> Separate execution logic from

application> Modular grouping of logic

> Standard vs. Premium Customer order processing

> Process will be updated without redeploying the application

> Coordinate asynchronous, potentially long running work

Page 6: Spice Up Your Applications  with WF 4

customer

Page 7: Spice Up Your Applications  with WF 4

Loading Workflow

<Activity x:Class=“Foo" > <x:Members> <x:Property Name="argument1“ Type="InArgument(x:String)" /> <x:Property Name="argument2” Type="InArgument(x:String)" /> </x:Members>

Foo.dll

C# (DynamicActivity)

Activity x = ActivityXamlServices.Load(xamlFile);WorkflowInvoker.Invoke(x, new Dictionary … );

Compile via XAML Build Task

Execute withDynamicActivity

Page 8: Spice Up Your Applications  with WF 4

Foo

WorkflowInvoker

WorkflowInvoker.Invoke(new foo)

Page 9: Spice Up Your Applications  with WF 4

WorkflowApplication

var wa = new WorkflowApplication(new Foo)

FooFoo

Foo

wa.Run()wa.Persist()wa.Cancel()wa.ResumeBookmark()wa.Unload()

Page 10: Spice Up Your Applications  with WF 4

WorkflowServiceHost

WorkflowServiceHost

FooFooFoo

Page 11: Spice Up Your Applications  with WF 4

HostWorkflowApplication

WF Persistence Basics

Idle

wa.Persist()

Page 12: Spice Up Your Applications  with WF 4

Tracking Participant

Collecting Workflow EventsWorkflow Runtime

Scheduler

Monitoring Data

raises events

Tracking Provider

Application Host

Tracking Profileaddnotify

Tooling

Page 13: Spice Up Your Applications  with WF 4

embedded process engine

demo

Page 14: Spice Up Your Applications  with WF 4

Custom Activities

Page 15: Spice Up Your Applications  with WF 4

Custom Activities> Activities are the mechanism to do the

important work in your domain> Customize the authoring components

for the logic in your application> Compositional model allows you to

create the right level of abstraction for authoring

> Replicate the real world in your building blocks (custom composites)

Page 16: Spice Up Your Applications  with WF 4

Customer –xRM Application Framework> Declarative development of

relational business applications using flexible models and dynamic services.

> Business Application Services> Multi-tenant controller> Event pipeline, solution sandbox,

audit, data quality, client sync, indexing

> Robust web services> Enterprise-scale, role-based

deployment

Multi-tenant controller

Entities

SQL

Workflow Security

Client

Forms / Views

Application models

in metadata

Page 17: Spice Up Your Applications  with WF 4

customer

Page 18: Spice Up Your Applications  with WF 4

Activity Authoring

Activity

CodeActivity

AsyncCodeActivity

NativeActivity

DynamicActivity

Page 19: Spice Up Your Applications  with WF 4

Control Flow Styles> Execution pattern for composite

activities> Any activity can be the root> Control flow activities can be

composed

Activity 1

Activity 2

Activity 3

ABC

D

Parallel

Activity 4

Activity 1

Activity 2

Activity 3

Delay (TimeOut

)Approve

Action A

Reject

Action B

PickBranch PickBranch PickBranch

Action C

Page 20: Spice Up Your Applications  with WF 4

ActivityAction> Creating a mechanism to let your

workflow authors to plug custom logic into your activity at prespecified “holes”

> Consumers extend an activity in a natural way, through more activities

Process Order

Receive Order

Reserve Inventor

yShip

Order

Approval

Payment

Page 21: Spice Up Your Applications  with WF 4

Custom Activities

demo

Page 22: Spice Up Your Applications  with WF 4

Customized Authoring Environment

Page 23: Spice Up Your Applications  with WF 4

Customized Authoring Environment> Visualization of process> Visualization of instance information> User construction or editing of process

definition> Customize the visualization of an

activity

Page 24: Spice Up Your Applications  with WF 4

customer

Page 25: Spice Up Your Applications  with WF 4

Custom Activity Designers

Surface key dataDisplay containedelements

ExpressionTextBox

WorkflowItemPresenter

WorkflowItemsPresenter

Page 26: Spice Up Your Applications  with WF 4

Host

Designer

Editing Context ItemsServices

Designer Rehosting

Page 27: Spice Up Your Applications  with WF 4

Customized Authoring Environment

demo

Page 28: Spice Up Your Applications  with WF 4

MS Research – Trident

Page 29: Spice Up Your Applications  with WF 4

Summary> Highlighted 3 different aspects of WF

in your app> Showed key types for using WF> The activity model provides a lot of

power, write custom activities!> Designer rehosting brings workflow

visualization into your application

> Highlighted some interesting applications built by our internal customers

Page 30: Spice Up Your Applications  with WF 4

Next Steps> File… New Project… Workflow> Other talks @ PDC

> Workflow Internals, next session, this room.

> WF Services, WCF and AppFabric talks tomorrow

> Chalk talks

> Come see us in the booth!

Page 31: Spice Up Your Applications  with WF 4

Q & A

Page 32: Spice Up Your Applications  with WF 4

Breakouts> FT25: Microsoft Application Server Technologies: Present and Future -

Tuesday, 1:30, 515A> FT04: Windows Workflow Foundation 4 from the Inside Out – Wednesday,

3:00 502A> FT17: Spice Up Your Applications with WF 4  - Wednesday, 1:30, 502A> FT13: What’s New for Windows Communication Foundation 4  - Wednesday,

10:00 Petree Hall D> FT14: Workflow Services and “Dublin”  - Wednesday, 11:30 Petree Hall D> FT27: Application Server Extensibility with Microsoft Project Code Name “Dubl

in” and Microsoft .NET 4  - Thursday, 1:45 Petree Hall D

> Scaling Your Data Tier with Microsoft Project Code Name “Velocity” - Thursday, 1:45 403AB

> CLI06: Networking and Web Services in Silverlight  - Wednesday, 3:00 Hall E 151

> SVR15: Microsoft BizTalk Server Futures and Roadmap  - Tuesday, 3:00 502A> SVR16: Connecting Applications with the Microsoft BizTalk Enterprise Service

Bus  - Tuesday, 4:30 515B

> FT55: Developing REST Applications with the .NET Framework – Wednesday, 11:00 Hall E 151

Page 33: Spice Up Your Applications  with WF 4

Chalk Talks> Monitoring and Managing “Dublin”

Services> State Machine Workflow Futures> Migrating Workflows from WF 3.5 to

WF 4> Visual WF Tracking and Debugger

Rehosting

Page 34: Spice Up Your Applications  with WF 4

Hands On Labs> Introduction to Windows Workflow Foundation in .NET 4> Introduction to Workflow Services in .NET 4 > What’s new in WCF 4?> Introduction to Microsoft Project Code Name “Velocity”> Introduction to BizTalk Server 2009 Demo: Process Automation

Solution with SharePoint & WF > Introduction to the BizTalk ESB Toolkit: Providing Service Integration

Agility

Page 35: Spice Up Your Applications  with WF 4

Web Resources> WCF Developer Center

> http://msdn.microsoft.com/wcf> http://msdn.microsoft.com/wcf/rest

> WF Developer Center> http://msdn.microsoft.com/wf

> BizTalk Developer Center> http://msdn.microsoft.com/biztalk

> AppFoo Developer Center> http://<>

> Team Blog: > http://blogs.msdn.com/endpoint

> Nicholas Allen’s Blog> http://blogs.msdn.com/drnick

> Matt Winkler’s Blog> http://blogs.msdn.com/mwinkle

Page 36: Spice Up Your Applications  with WF 4

Resources> Trident

> http://research.microsoft.com/en-us/collaboration/tools/trident.aspx

Page 37: Spice Up Your Applications  with WF 4

xRM @ PDC 2009> Visit us at the booth in the pavilion> Try hands on labs

> Extending CRM5 and Solutions Packaging> Building CRM5 Data Visualizations and Dashboards

> Attend sessionsCODE TITLE TIME PLACEPR01 Developing xRM Solutions Using

Windows Azure: Cloud-based Business Applications

Thurs 3:00p 502A

PR31 Managing the Solution Lifecycle for XRM Applications

Tues 12:30p

515A

PR33 Build a .NET Business Application in 60 Minutes with xRM and SharePoint

Thurs 12:45p

502A

Page 38: Spice Up Your Applications  with WF 4

YOUR FEEDBACK IS IMPORTANT TO US! Please fill out session evaluation

forms online atMicrosoftPDC.com

Page 39: Spice Up Your Applications  with WF 4

Learn More On Channel 9> Expand your PDC experience through

Channel 9

> Explore videos, hands-on labs, sample code and demos through the new Channel 9 training courses

channel9.msdn.com/learnBuilt by Developers for Developers….

Page 40: Spice Up Your Applications  with WF 4

© 2009 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

Page 41: Spice Up Your Applications  with WF 4