Showing posts with label BPMN. Show all posts
Showing posts with label BPMN. Show all posts

Thursday, October 13, 2011

Using Visio 2010 BPMN* To Design, Model and Document BizTalk solutions

 

The PowerPoint 2010 Presentation, Visio 2010 BPMN Sample, and Excel Attribute Shape Report used for the Lake County .NET Users Group Oct 13: Visio 2010 Business Process Modeling Notation (BPMN) are available for download form my Skydive Public Folder.


  

Wednesday, October 12, 2011

The BPMN modeling procedure

Its purpose is,

To analyze a building block (what it is supposed to do)
To synthesize its implementation (how it does this) as the explicit coordination of other building blocks (processes or activities)
It is iterative – we can apply it until we have left only indivisible building blocks (i.e. activities)
Artifacts are constructed recursively

Principles of the modeling procedure

it treats human and automated activities equally
it is primarily for capturing the flow of control, and not for optimization
it is a tool for both the business and the IT
it provides validation by simulation
it provides validation by quick prototyping – real services can be invoked
it is a visual programming approach

General BPMN Modeling Concepts

General Modeling Concepts

  • A process is chronological. Accurate models should be oriented on a time line (in general, from left to right in sequence).
  • Processes generally begin with triggering events, and work their way through to significant business results.
They can also represent smaller segments of re-usable work.
  • All tasks or activities are assigned to roles that are meaningful to people in the business.


Be sure you have captured all relevant roles, which may sometimes be outside of the company.

  • A complete model should display how objects or data (or both) are transferred and where they are going.
  • A process can be modeled in a hierarchical fashion (e.g., with Sub-Processes).
  • The choices made for decisions, which occur within a process, determine which of all possible paths will be taken.
  • Establish organization standards or guidelines for developing models and naming model elements, e.g.,
Establish naming conventions for each type of modeling object. For example, all activity names could have the following format:  

verb + (adjective/descriptor) +

Avoid redundancy in naming, e.g., do not include the word Process in the Process names or the words Task or Activity in Task names.
To help with report outputs, names should be 32 characters or less.
To help with readability, all words should be capitalized.
  • Establish a set of standard nouns, verbs, and acronyms that are used for naming objects.
  • Establish standards for versioning methods associated at the process model and artifact level to provide requirement traceability.

Saturday, October 8, 2011

Using Visio 2010 Premium to create a BPMN Document

 

Creating a New Visio 2010 BPMN Document

The following step will show you how to create the document and setup your workspace

1. From the Visio File Menu Select “Flowchart”.

2. Select “BPMN Diagram”.

image

 

 

 

3. From the BPMN Basic Shapes, drag a “Start Event” shape onto the page.

4. “Right click” on the “Start Event” shape and click on “BPMN Attributes” as shown below.

image

 

 

 

 

 

 

 

 

5. Position the “Shape Data” window as shown in the example below.

image

 

 

 

 

The Visio 2010 BPMN Shapes

Basic Shapes

image

 

 

 

 

 

 

BPMN Event Shapes

image

 

 

 

 

 

 

 

 

 

BPMN Activities

image

 

 

 

 

 

 

 

 

BPMN Gateways

image

 

 

 

 

 

BPMN Connecting Objects

image

 

 

 

 

 

 

Visio 2010 BPMN Menu Items

The Visio 2010 “Process Menu”

image

 

 

 

 

Check Diagram

When you “click” on the “Check Diagram” in the menu, all the pages in your document are validated against the “built-in” BPMN Validation Rules.

If the “Issues Window” item is checked, you will see the”Issues Window” as show in the sample below.

Issues Window

image

 

 

 

 

If the diagram fails validation you are presented with the error information as shown in the sample below

Issues Window with errors

image

 

 

 

“Double Clicking” on the line will highlight the where the issue occurs within the diagram.

 

Subprocess Menu Items

Link to Existing

If you select a shape on your drawing and then “click” on the “Link to Existing” menu item, you are presented with a drop down menu as show below.

Pages in this Document

image

 

 

 

 

 

You can create a “hyperlink” from the selected shape to any page within the document.

If you select “Browse to Other Document”, you can also create a “hyperlink” to any file type this can be an Excel Mapping document, Message Schema, Message sample, Business Rule Document, etc.

Create New

If you select a “Sub-Process” shape in the diagram and select “Create New” in the menu, a new diagram page is created. The page is named from the shape.

A hyperlink is created from the selected shape to the new page.

Create from Selection

If you select a group of elements on a page and select “Create from Selection”, this will create a new “Sub-process” Page. A new shape is added to replace the shapes moved to the new page.The page name is not labeled for the sub-process.

An example of the shape is shown below.

Sub-process link shape

image

 

 

 

Monday, September 12, 2011

Business Rules and Business Process Exceptions

Often a business process team will create a working prototype of a business process. These prototypes might arise from 'use-cases' or business cases.

This idealized process develops a deep understanding of the final version, yet much of the important work remains. You should even consider executing this development artifact in a test bed. Yet to complete a business process, the technical team should detail the process diagram with the necessary scheduling, exceptions and compensations. The purpose of the details is to erect a more complete process model. The business processes should act on all the messages, including the system failures. The process should handle every anticipated exception.

There are 3 types of exceptions may affect process execution:

  • Technical exceptions
  • Transient exceptions
  • Business exceptions

As we will see, business rules can create, named business exceptions. If a BizTalk Orchestration is transactional, the process should compensate for transactions that fail to complete. In compensation, the process cleans up or backs out records from ERP’s, operational datastores or data warehouses.

Often processes should be complete within a time period, so there could be time out actions noted on the diagram. Business processes usually receive a message and translate that message into yet another message for consumption by the next part of the process. BPMN is powerful for developing time-outs, exceptions and compensations. As seen in the BPMN fragment below, you can attach time-outs, exceptions and compensations directly to a subprocess task list. When time-outs and exceptions occur within the two process tasks, the BizTalk Orchestration traps these at the point of the subprocess.

 

image

Figure 1 BPMN fragment

In this scenario, a grant authorization system evaluates grants and records the data. The time-out BPMN (the clock) will raise a time-out exception and wait. The diagram reports any exception that occurs (the zigzag) to the exception task. The compensation takes care of a record in the grant database.

You can model Business Processes with advanced abilities that suspend processing, or communicate with disconnected, mobile processes. These powers yield opportunities for the enterprise to fine-tune their most complicated practices. Yet to develop these capabilities you should understand how to handle the three types of exceptions and what you must plan for when developing the production version of the process diagram.

A business process diagram should use exception handlers to redirect the process flow in case a transient or business exception happens. However, no process can manage every exception. There are technical exceptions that will cause the entire process instance to suspend.

 

Technical Exceptions

Technical exceptions occur when the process causes the process instance to fail. An internal server exception should be abnormal; however there are operational circumstances that cause these. Technical exceptions include:

The common .Net Null exceptions

  • Exceptions caused by Illegal Argument exceptions, (suppose an external operational system decides to change a field from 10 to 20 characters)
  • Server database exceptions, out of tablespace, violation of database constraints

These are outside and therefore invisible to the calling subprocess. Processes cannot handle them because the execution state of the process has stopped. When this technical exception happens, the current transaction is always marked for rollback. The process throws the exception to the scheduler or message router.

 

Transient exceptions

A transient exception is usually caused by code external to the server like database connections or connection pooling exceptions. Within the scope of the current transaction, a transient exception is visible and the process can catch it with an exception handler. If the exception is not handled in the scope of the current transaction, the subprocess marks the transaction for rollback and throws the exception to the scheduler or message router. The process is suspended.

The suspended process can be restarted and resume processing after the database connection or some other condition is restored.

 

Business Exception

A business exception is one that can be expected by the process. Examples of these exceptions include:

  • ·Exception raised by an activity, a specific, named exception is raised, for instance a business rule could raise a named exception.
  • Exception caused by receiving an error message (like an SOAP fault).

If the exception is not handled in the scope of the current activity, the activity fails. When the activity defined a coordinated transaction, the transaction is committed. When no exception handling takes place Exception processing begins and leads to compensation and the failure of the process.

 

Business Rules Decisions and Business Exceptions

Many organizations use the BizTalk 2010 Business Rules Engine (BRE) to validate and transform incoming transactions. Validations and transformation are important types of 'decisions' that a business process makes with the data within process flows.

This is a common decision pattern: evaluate a set or transactions, say from an incoming data set. Each record that fails the validation should be stored in an area for latter cleanup. You can either handle the validation directly, with values in the process flows or you can raise a business exception, create a reusable process for handling the exception and move on.

Another common decision pattern validates user form input, in a workflow. Users might correctly complete a form and send it to a process flow. If there are business rules that violate complex data and business conditions, the process should collect data from the user at a later date.

Figure 2 is an example of what I am describing. A decision service validates incoming data. If the data does not pass validation, the subprocess raises a named exception, otherwise the record is processed.

image

Figure 2 Decision Services

The basic idea is to design your exceptions, time-outs and compensations to enlarge the flexibility of the process and allow most process to continue unattended. Handle the process and move on.

 

Diagram complexity

The complete BPMN diagram has many important exception features that must be accommodated.

Unfortunately, these additional boxes and notations make it difficult for business users to understand. This is where you use a BPMN Structuring Phase diagram. This diagram does not display exceptions, compensations and timers attached to subprocesses. The tasks following these should also not be displayed. This would clarify the core nature of the process and provide your business users an easy to understand document.

 

Windows Live Tags: Rules,Exceptions,Often,team,prototype,prototypes,version,development,artifact,diagram,compensations,purpose,messages,system,failures,exception,execution,Technical,Transient,BizTalk,Orchestration,transactions,compensation,data,warehouses,message,consumption,BPMN,task,tasks,Figure,scenario,authorization,clock,database,Processes,abilities,opportunities,enterprise,capabilities,production,handlers,instance,server,Null,Illegal,Argument,violation,constraints,transaction,connection,Within,scope,handler,Examples,error,SOAP,failure,Decisions,Many,Engine,Validations,transformation,decision,validation,area,cleanup,Another,user,Users,example,Services,Handle,notations,Phase,timers,Tags,outs,rollback,scheduler,router

Friday, September 9, 2011

Using BPMN to design and document BizTalk 2010 Projects

 

The following are the recommended steps to design and document a BizTalk 2010 Project using Visio 2010 Premium – BPMN

1. The Project Manager and Business Analyst will create the Functional Requirements documentation.

2. The BizTalk Architect or Lead BizTalk Developer will create a new Visio 2010 BPMN document for the project.

3. The BizTalk Architect or Lead BizTalk Developer will create the “Black Box” BPMN diagram.

4. The Project Manager and Business Analyst will review the diagram to validate that it meets the project requirements.

5. The BizTalk Architect or Lead BizTalk Developer will then add a new tabs for the BPMN Structuring Phases (1 -3). The Structuring Phase diagrams will be constructed.

6. The Business Analyst will use the Structuring Phase diagrams to determine what supporting documents need to be created. These documents include; Transformation (Maps), Business Rules, etc...

7. The BizTalk Architect or Lead BizTalk Developer will validate the Structuring Phase 3 BPMN Diagram for any errors.

8. The BizTalk Architect or Lead BizTalk Developer will add a new tab for the Reconstruction Phase Diagram.

9. The BizTalk Architect or Lead BizTalk Developer will create the Reconstruction Phase Diagram.

10. The Business Analyst will validate the Reconstruction Phase Diagram.

11. The Business Analyst will add a new tab for the Instrumentation Phase Diagram.

12. The Business Analyst will attach the documents to the Shapes within the Instrumentation Phase Diagram.

13. The Business Analyst will enter the attributes values for each shape in the Instrumentation Phase Diagram.

14. The BizTalk Architect or Lead BizTalk Developer will validate the Instrumentation Phase Diagram.

Tuesday, September 6, 2011

BPMN Diagramming Basics

Microsoft has recently published a Training Course, "Learn the basics of Business Process Modeling Notation (BPMN) and how create a BPMN flowchart diagram in Visio 2010 Premium" on the MS Office Support site.

I highly recommend this for anyone involved in designing BizTalk Solutions.  The BPMN shapes and attributes relate to BizTalk Orchestrations.

Tuesday, July 5, 2011

Using BPMN to document BizTalk Solution Requirements - Part 1

I have been working with BPMN for a few years. My primary tool has been Enterprise Architect by Sparx Systems. Microsoft introduced BPMN 1.2 in Visio 2010 Premium Edition. I have recommended both products on almost every BizTalk Contract.

On my last contract, I taught several classes (Project Managers, Business Analysts, Architects and Developers) on the use of BPMN and how it relates to BizTalk Applications. They are using it not only for BizTalk, but all Business Process Applications.

BizTalk 2006 had a nice addin for Visio, the "Microsoft BizTalk Server 2006 Orchestration Designer for Business Analysts".  A Business Analyst could create an Workflow in Visio and a BizTalk developer could use the diagram to create the Orchestration.

I have been researching how to do the same thing with BPMN. 

To be continued...