Defining the Business Process


Designing and implementing a business process with BizTalk Server involves several steps. These typical steps require collaboration between the business analyst and the implementing developer:

  1. Define the data document: Carefully design and store the data that enters and exits the business process as an XML template. Document definitions validate documents before processing.

  2. Draw the business process diagram: Draw all the necessary business processes, including decisions and exceptions. Each process comprises multiple actions that are graphically drawn and linked together to complete a process.

  3. Implement the business process: The business process diagram must be implemented by placing functional objects, such as COM and script components that implement business logic, into the Orchestration diagram.

  4. Bind the business process to the implementation: Establish the connection between the process diagram and the implementation shapes that provide the business logic.

  5. Perform data flow mapping: Specify the flow of data and transformations from the source document throughout the business process to an end document.

  6. Compile the schedule: Translate the business process diagram into an XML file representation that can be interpreted by the process engine.

  7. Create the message port: Define the entry and exit points for business documents entering and exiting the business process.

  8. Create the message channel: Define the data document path from initial discovery through delivery to the message port and any encryption or transformation needed in between.

BizTalk Server includes the tools that work together to accomplish these business process development steps.

Defining the Data Document

As mentioned earlier, it is important for businesses to use the same language for describing the documents passed between them. In today's enterprises , this common language is XML. Although XML documents are stored in a text format and can be opened with any text editor, creating or modifying them manually is a tedious and error-prone process. The BizTalk Editor, shown in Figure 6-4, helps to simplify this step.

click to expand
Figure 6-4: The BizTalk Editor used for XML document definition

The BizTalk Editor provides a way to visualize a document's layout, define data types for individual elements and attributes, and define whether data fields are required or optional. Although the schema representation in the BizTalk Editor looks similar to EDI and flat-file schemas, it is still an XML editor that produces structured XML documents.

Using the WebDAV Repository

BizTalk Messaging expects a document's structure to remain generally unchanged and located in the same place. BizTalk Messaging interacts mostly with documents stored in a central document repository that is compliant with World Wide Web Distributed Authoring and Versioning (WebDAV). WebDAV is the Internet Engineering Task Force (IETF) standard for collaborative authoring on the Web, and it supports collaborative editing and file management between users. Although the BizTalk Editor can read and write files anywhere in the file system, completed documents should be stored in the WebDAV repository.

To store documents within the WebDAV repository, use the BizTalk Editor to create the document. Next , choose File ˜ Store to WebDAV to save completed documents into the WebDAV repository. Enter NewIssue.xml as the filename. You can create multiple document definitions based on the same schema document, and you can optionally define global document tracking options for each document definition.

Diagramming with Orchestration

The next step in the business process development is to define and diagram the specific business process activities. A business analyst or domain expert using BizTalk Orchestration typically performs this diagramming.

The business analyst defines the business process using basic shapes, such as Action, Decision, and While shapes. The business analyst is not required to think in terms of documents, specifications, components, or messages. The developer addresses these implementation details later. Any number of the steps can appear in a business process. Fork shapes can split a process into multiple concurrent paths, such as requesting the same price quote from multiple suppliers. Later, these paths can reunite with a Join shape. Also, the Transaction shape can encapsulate several steps of the business process into a single activity.

Figure 6-5 shows the IssueTracker business process, which might be described as follows : First, a new issue document is received by the business process. Next, this document is validated and forwarded to the next step. The issuePriority field of the document is evaluated by a business rule. If issuePriority evaluates to High, then an e-mail message is sent to the administrator. In any case, the resulting document is logged into the IssueTracker database and the process ends.


Figure 6-5: Diagramming a business process with the BizTalk Orchestration Designer

Because BizTalk Orchestration supports long-running business processes, they may need to be suspended and saved to conserve computing resources and provide extra reliability. BizTalk Server later restarts these sleeping processes from the exact point they were suspended. If the server running BizTalk Server is switched off, the suspended processes are restarted when the system is eventually restored.

Adding Business Rules

The Decision shape implements the business rules. After placing a Decision shape in the process diagram, right-click the Add Rule pop-up menu item. Select Create New Rule and enter the business rule definition, as shown in Figure 6-6.

click to expand
Figure 6-6: Applying business rules based on properties within the document

To add a specific script expression, select a message item from the Message list and a field item from the Field list. Click the Insert button to insert the specific data field to the script expression textbox. From the script expression textbox, you can include additional constants or expression code to complete the rule. For IssueTracker, this rule evaluates the PriorityID for the IncomingMessage and compares it to the condition of 1. If the expression is true, the process diagram will continue with additional steps.




Developing. NET Enterprise Applications
Developing .NET Enterprise Applications
ISBN: 1590590465
EAN: 2147483647
Year: 2005
Pages: 119

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net