Connected Applications using WF and WCF

17 %
83 %
Information about Connected Applications using WF and WCF

Published on June 19, 2008

Author: maddinapudi

Source: slideshare.net

Description

Connected Applications using WF and WCF

Building Connected Application using WF and WCF Sarang Datye sarang.datye@microsoft.com http://www.dotnetbetaworks.com

Agenda Modeling processes via WF Exposing and consuming services via WCF

What is Workflow? The workflow framework and tools for Microsoft products and partner/customer ecosystem Single workflow technology for Microsoft® Windows® A framework for building workflow, not an application or server Make declarative workflow a mainstream development paradigm

Why Workflow? Workflow Value-Add Real-World Examples Long Running and Stateful “Orders are confirmed in Workflows run for up to 30 48 hours and shipped days and maintain state within 30 days.” throughout “Most suppliers Flexible Control Flow confirm our orders but Flexibility for people to some forget and we override or skip steps in need to follow up.” the workflow Transparency “What are the next steps Rendering a visualization of in handling this order?” next steps based on defined control flow

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

Extensible Activities Domain-Specific Custom Activity Base Activity Workflow Packages Libraries Library Compliance CRM Extend Compose activity activities Out-of-Box RosettaNet (OOB) Activities Author new activity IT Mgmt OOB activities, workflow Create/Extend/ types, Vertical-specific activities Compose activities base types and workflows App-specific building General-purpose Best-practice intellectual blocks Activity libraries property (IP) and First-class citizens define workflow knowledge constructs

Runtime Extensibility Host App Domain Runtime Out of Box Services are provided that support SQL Services Server 2000 & 2005 PersistenceService stores and retrieves PersistenceService SQL instance state. TrackingService TrackingService manages profiles and SchedulerService stores tracked information. TransactionService Common resource services for managing threading, timers and creating transactions

Workflow Services Advantages Service implemented as Workflow Leverage Workflow development experience Enforces application protocol by default Allows long-running, durable Services Workflow hosted as Service ServiceContract provides typed interface for integrating with the Workflow Messages enforce by-value, serializable data Workflows can be message-activated

Workflow Service Architecture Service.cs Workflow.cs or Workflow.xoml Service Instance Workflow Instance Service Runtime OperationInvoker Operation 1 ReceiveActivity 1 WorkflowOperationInvoker App.config OperationSelector Operation 2 ReceiveActivity 2 Workflow ServiceHost ServiceHost InstanceProvider DurableInstanceProvider Workflow Runtime MessageInspector MessageContextInspector ServiceDescription ContextChannel WF Persistence DB ServiceBehavior WorkflowServiceBehavior ListenerChannel OperationBehavior WorkflowOperationBehavior

Getting Started with WF

Agenda Modeling processes via WF Exposing and consuming services via WCF

The Imperative to Connect MOBILE EMPLOYEES CUSTOMERS CUSTOMERS MOBILE EMPLOYEES

WCF is: Our next-generation platform for distributed systems A set of extensions to the Microsoft.NET Framework 2.0 Build WCF services in Visual Studio 2008 using any .NET Language Intelligent code editing, IDE Extensions for WCF, debugging, re-factoring, code snippets, etc. Visual Basic .NET, Visual C#, etc. Runs on Microsoft Windows Vista Microsoft Windows XP Microsoft Windows Server 2003 Part of .NET 3.0 and .NET 3.5

Benefits of WCF Unifies today’s distributed technologies Unification Lets you develop/deploy/manage one model Visual Studio 2008 integration Broad support for Web services Interoperability (WS-*) specifications and REST Single stop shop for building services Enables development of Service-Oriented loosely-coupled services Development Config-based communication

Unified Programming Model .NET Remoting ASMX & WSE Interop Extensibility with other Location transparency Platforms & WS-* Attribute- Message- Based Oriented REST / HTTP Programming Programming Programming Enterprise System.Messaging Services HTTP Services

A Look at WCF (1) Client Service Endpoint Message Endpoint Endpoint

A Look at WCF (2) Client Service A B C Message C B A A B C Address Binding Contract (Where) (How) (What)

Productivity Using Visual Studio .NET 2003 class HelloService { 20,379 lines [WebMethod] security public String Hello(String Greeting) { X509CertificateCollection collection = new X509CertificateCollection(); 5,988 lines IntPtr blob = Marshal.AllocHGlobal(Marshal.SizeOf( reliable messaging typeof(CRYPTOAPI_BLOB))); IntPtr data = (IntPtr)((int)blob + Marshal.SizeOf(typeof(CRYPTOAPI_BLOB))); … 25,507 lines transactions SeqAckRange range = new SeqAcknRange(id, low, high ); SeqAckRange[] ranges = { range }; ReliableQueue.ProcessAcks( ranges ); … 4,442 lines infrastructure BeginTransaction (NULL, ISOLATIONLEVEL_SERIALIZABLE, 0, pITxOptions, &pITransaction); … Total lines 56,296 return Greeting; } }

Productivity Using Visual Studio .NET 2003 and WSE class HelloService { [WebMethod] public String Hello(String Greeting) { 10 lines foreach ( SecurityToken tok in security requestContext.Security.Tokens { X509SecurityToken token = tok as X509SecToken 1,804 lines } reliable messaging … SeqAckRange range = new SeqAcknRange(id,low,high ); SeqAckRange[] ranges = { range }; 25,507 lines ReliableQueue.ProcessAcks( ranges ); transactions … BeginTransaction (NULL, ISOLATIONLEVEL_SERIALIZABLE, 0, pITxOptions, Total lines 27,321 &pITransaction); … return Greeting; } }

Productivity 2005 and WCF Using Visual Studio [ServiceContract] class HelloService { [OperationContract] 1 code + 2 config (elem.) [PrincipalPermission(SecurityAction.Demand, Role = “Adminstratorsquot;)] security [TransactionFlow(TransactionFlowOption.Mandatory)] [OperationBehavior(TransactionScopeRequired = true, 0 code + 1 config (elem.) TransactionAutoComplete = true)] String Hello(String Greeting) {return Greeting;} reliable messaging } <bindings> 2 code + 1 config (attr.) <wsHttpBinding> transactions <binding name=quot;Binding1“ transactionFlow=quot;truequot;> <security mode=quot;Messagequot;> <message clientCredentialType=quot;Windows“/> Total lines: </security> 3 code (what) + 4 config (how) <reliableSession enabled=quot;truequot; /> </binding> </wsHttpBinding> </bindings>

Getting Started with WCF

© 2008 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.

Questions…

Add a comment

Related pages

connected_applications_using_wpf,wcf_and_wf-(sarang_datye ...

connected_applications_using_wpf,wcf_and... by Sarvesh M. 10,733 KB | 2009-03-01 | Windows Media Video File |
Read more

VS2008 Training Kit: Connected Application Foundations ...

VS2008 Training Kit: Connected Application Foundations using WCF, WF, and Windows CardSpace. ... VS2008 Training Kit: Connected Application ...
Read more

WCF | The .NET Endpoint | Page 10

Blog by the .NET and AppFabric teams about WCF and WF development, deployment, and management. Tag: WCF ... Creating Connected Applications ...
Read more

Integrating Windows Workflow Foundation and Windows ...

An overview of how workflows built by using WF can be hosted ... Sample Integrating WF and WCF." ... to develop connected systems easily ...
Read more

MS Virtual Labs: Connected Applications with WCF and WF ...

MS Virtual Labs: Connected Applications with WCF and WF. Posted: May 04, 2009 at 3:41PM ... MS Virtual Labs: Connected Applications with WCF ...
Read more

BizTalk + WF/WCF, Better Together - TechNet Articles ...

BizTalk + WF/WCF, Better Together ... Click the Connect button to ... in IIS to run in a different Application Pool that is using an identity with an ...
Read more

Connected Systems Roadmap for WCF, WF, ‘Dublin’ | US ISV ...

... (WF), collectively known as connected ... management experience for WCF and WF applications. ... Connected Systems Roadmap for WCF, WF, ...
Read more

Difference between Workflow service and a regular WCF Service

Difference between Workflow service and a ... enabled applications using ... it is a WCF service that host a .net application ...
Read more

Windows Workflow Foundation integration with Windows ...

Windows Workflow Foundation Windows Workflow Foundation ... to give you an overview of how to use it in your WF/WCF applications. Communicating using WCF.
Read more