Summary of WF

Source: Internet
Author: User

It's almost a month before the opening. Let's summarize the 60 articles published.
WF is not a business platform, but a platform for developers to create workflow software. That is to say, WF is not a workflow application platform, but a platform for developing workflow applications.

1. Use WF to develop a workflow platform with the following features
1. Business Process-assisted office software
2. Smooth control of internal software work
3. automatically filter Query Systems
4. Automatic Control in progress

Ii. WF is released as part of net3.0. To run it, you must install net3.0.

WF provides a designer for Visual Workflow design in VS2005. Visual Studio 2005 Extensions for Windows Workflow Foundation can be created in VS2005 only after installation.

Iii. WF provides two types of workflow modes: stream mode (Sequential) and State Machine mode (State Machine ), we can simply regard the state machine pattern as a stream pattern with interaction points and Goto commands, and design a workflow. In fact, there is no pattern. We use the state machine pattern to determine the process and manage the business status, the stream mode is used as a sub-process to complete specific business operations.

4. WF provides a series of Activity controls for workflow design. There are two types:
Simple work class (System. Workflow. ComponentModel. Activity)
Container class (System. Workflow. ComponentModel. CompositeActivity ),
Activity <-CompositeActivity

Includes the following controls:
CodeActivity: code can be added,
IfElseActivity: similar to the if statement,
SuspendActivity: similar to a thread suspension statement,
DelayActivity: similar to a thread sleep statement,
CallExternalMethodActivity: similar to calling a method statement,
HandleExternalEventActivity: similar to the trigger event statement,
WhileActivity: similar to the While statement,
TerminateActivity: similar to the termination statement,
ThrowActivity: similar to a custom exception statement,
ConditionedActivityGroup: a bit like a foreach statement,
ReplicatorActivity: a bit like a for statement
PolicyActivity: a bit like a responsibility chain
You can use InvokeWebServiceActivity to call WebService.
You can use WebServiceInputActivity and WebServiceOutputActivity to publish a workflow to WebService.
You can use InvokeWorkflowActivity to call a subflow.
There are also some controls used to control processes, control statuses, transaction processing, and exception handling.

5. A workflow exists as a template and runs as an instance
The workflow template of WF can be a NET class library file compiled into DLL, or a string that depicts the node relationship in XML, A workflow instance is a set of status data that each user uses to implement a specific business based on the track defined by the template. instances must run in the engine and can be saved to databases or disk files.
A workflow provides an engine for running instances. The engine is not released in the form of an independent service, but can be parasitic in any process in the form of an independent thread. A parasitic program is called a host. The host and engine can interact with each other through interfaces, control the engine, and communicate with workflow instances in the engine.
The engine can run multiple instances at the same time, and the host can run multiple engines at the same time.

6. WF provides a series of engine loading services, listener, and data communication ExternalDataExchange
1. Persistence Service
WF provides SqlWorkflowPersistenceService, which is used to persist the instance to a database. The database generated file of SqlWorkflowPersistenceService is in [System Disk \ Windows \ Microsoft. sqlPersistenceService_Schema. SQL and SqlPersistenceService_Logic. SQL under NET \ Framework \ v3.0 \ Windows Workflow Foundation \ SQL \ EN]

You can also derive PersistenceService to create a custom persistence service.

2. Monitoring (Tracking) Service
WF provides SqlTrackingService, which is used to listen to the running status of the instance and save the status to data. The database generated file of SqlTrackingService is in [System Disk \ Windows \ Microsoft. tracking_Schema. SQL and Tracking_Logic. SQL under NET \ Framework \ v3.0 \ Windows Workflow Foundation \ SQL \ EN]
You can use SqlTrackingQuery to query the instance status from the database.

You can also derive TrackingService to create a custom listening service.

You can customize TrackingProfile to filter the content to be monitored.

3. Data Communication Service
WF provides ExternalDataExchange for communication between the host and the instance. CallExternalMethodActivity and HandleExternalEventActivity depend on this service.

4. Other services, such as ManualWorkflowSchedulerService, run the instance in one-way mode, which is useful when the instance interacts with external devices.

7. Customizable process designer
WF provides the System. Workflow. ComponentModel. Design. WorkflowView control, which displays the Workflow structure graphically.

8. You can use WorkflowChanges to dynamically add and delete nodes when the instance is running.

9. You can use WorkflowMarkupSerializer to convert the workflow template class to the XML string format.

10. WF provides rule objects for flow control activities

11. WF provides WorkflowRole objects that allow you to customize roles, use AD roles, and use ASP. NET20 roles.

12. Communication
A friend who is not familiar with WF and does not often develop multi-threaded applications has the habit of getting instances from the engine and then performing operations directly. This method is commonly used in single-thread development, there is no need to consider resource access conflicts. However, the relationship between instances in WF and the host and engine is the same as that in multi-threaded resources. Instances are exclusively controlled by engine threads and cannot communicate with instances directly, you must use a dedicated channel.
1. You can use startup parameters, dynamic nodes, and queue insertion to implement the instance push communication between the host and the engine,
2. You can also use CallExternalMethodActivity, HandleExternalEventActivity, or custom status points to implement the communication between the host and the instance PULL mode in the engine.

MS releases WF as a basic API of Vista, instead of an independent software (such as BizTalk, Office, CRM, and Exchange ), the intention cannot be simply to render the existing workflow business platform as simple as that. Maybe WF appears like VB, VB is a visual interface design, and WF may need to implement visual code design.
Has another reincarnation started?
Is it a brand new process-oriented development era?

What does MS do next? I don't know. DOM seems like IE4 in win98 is available. Now MS is setting off the Atlas boom.
Win95 has a Media Player and NetMeeting, But MS has been involved in media playback and instant messaging for nearly two years. It has been a secret for ten years.
In the beautiful swordsman dancing by MS, how many swordsmen have we realized?
MS is really amazing. I hope that his technology can be replaced with Inherits and then Overrides, instead of simply completing the New Invoke.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.