SlideShare a Scribd company logo
1 of 46
Download to read offline
Modeling and Validating
  BPMN Diagrams


  Michele Chinosi, Alberto Trombetta


 Universit` degli Studi dell’Insubria (Varese – Italy)
          a
   Dipartimento di Informatica e Comunicazione
         michele.chinosi@uninsubria.it

        BPMN 2009 Workshop
           July 20, 2009, Vienna, Austria
Contents Cloud




                 2/38
Agenda


BPMN 1.1 and 2.0 Analysis


Our BPMN Metamodel Proposal


The XML Linearization


Referential Integrity


Concluding Remarks




                                 3/38
Motivations




• need for easy usable models to test properties, to patch BPMN and
  to add new features
• other proposals (as well as BPMN 2.0 submissions) are quite unclear
  and too complex
• lack of validation support
• BPMN 1.1/1.2 comes without a native XSD
• methods to ensure diagrams correctness are manual and error-prone




                                                                        4/38
Contributions



  • simplified test-oriented version of the BPMN metamodel
  • self-validating XML serialization for BPMN diagrams
  • automated checks (using software tools)
  • our approach could be abstracted from the specificities of BPMN
    1.2 porting the base concepts also to BPMN 2.0

Last-Month Update
This work has been partially superseded by the recent BPMN 2.0 final
submission adoption by OMG. We will see a brief summary of major
changes at the end of this talk.




                                                                      5/38
Contributions



  • simplified test-oriented version of the BPMN metamodel
  • self-validating XML serialization for BPMN diagrams
  • automated checks (using software tools)
  • our approach could be abstracted from the specificities of BPMN
    1.2 porting the base concepts also to BPMN 2.0

Last-Month Update
This work has been partially superseded by the recent BPMN 2.0 final
submission adoption by OMG. We will see a brief summary of major
changes at the end of this talk.




                                                                      5/38
BPMN 1.1 Weak Points Analysis



• weak hierarchical structure of the model
    • BPD are strongly hierarchical
    • elements placement inside the model does not reflect the expected
      placement inside the diagram
• UML metamodel uses only generalization connections
     • no valid/meaningful instances
• lack of distinctions between several elements and types definitions
     • they are all elements (classes)
     • Connections-by-Types




                                                                         6/38
Sketch of BPMN 1.1 Metamodel




                               7/38
Different Hierarchical Structures Comparison




                                              8/38
BPMN 2.0 Overview
(B)IOS
 • (BEA), IBM, Oracle, SAP
 • execution semantics formalization
 • extensibility mechanism for both model and graphical extensions
 • event composition and correlation refinement
 • human interactions definition
 • choreography model

BPMN-S
 • Adaptive, Axway Software, HP, Lombardi Software, Fujitsu, et al.
 • business level modeling
 • checking compliance to choreography and rules
 • process taxonomies
 • execution interoperability
 • model re-usability



                                                                      9/38
Sketch of BPMN 2.0 UML – (B)IOS Proposal




                                           10/38
Sketch of BPMN 2.0 UML – BPMN-S Proposal




                                           11/38
Sketch of BPMN 2.0 UML – Final Submission




                                            12/38
BPMN 2.0 – The CORE UML Class Diagram Example




                                            13/38
BPMN 2.0 – The Package Diagram Example




                                         14/38
Our BPMN 1.1 Metamodel Proposal



• top-down fashion methodology
    • from BPD to all the other elements
    • strongly hierarchical model
• reduces the Connections-by-Types and deletes all the missing
  connections
    • BPMN Supporting elements treated as types
    • simpler model
    • Connections-by-Semantics (UML compositions)
• every BPD can be described as one valid instance of the model
• right positioning of Connecting flow objects




                                                                  15/38
Sketch of our BPMN 1.1 Metamodel Proposal




                                            16/38
The XML Linearization


BPMN ⊃ WS-BPEL                                        Still incomplete
                            ⇒ BPMN 2.0 ⇒              and
BPMN = XPDL                                           Complex

                      could be adapted to become
BPMN 1.1 → XML        −−−−−−−−−−−
                       −−−−−−−−−−→                    ⊆ BPMN 2.0



• Our linearization proposal could be useful to study diagram and/or
  model properties and to make some tests, as well as to validate both
  a model and its instances.




                                                                         17/38
The XML Linearization


BPMN ⊃ WS-BPEL                                        Still incomplete
                            ⇒ BPMN 2.0 ⇒              and
BPMN = XPDL                                           Complex

                      could be adapted to become
BPMN 1.1 → XML        −−−−−−−−−−−
                       −−−−−−−−−−→                    ⊆ BPMN 2.0



• Our linearization proposal could be useful to study diagram and/or
  model properties and to make some tests, as well as to validate both
  a model and its instances.




                                                                         17/38
Detailed BPMN 1.1 Weak Points Analysis
Attributes default values
  • BPMN defines mandatory attributes WITH default values
  • XML-Schema does not permit this double assertion
    if an attribute has the default clause defined, it takes the default
    value even if it is not present at all
    use=‘‘optional’’ + default=...

Process
 • BPMN defines Processes as conceptual siblings of the BPD
  • if a Pool shares a Process, then it has one or more Lanes
  • all the other elements are referenced by the Process using their IDs
 !! we don’t want a valid instance with Process as root element
    ∃ Process ⇒ ∃ Pool, but ∃ Pool       ∃ Process
    Process becomes child of Pool



                                                                           18/38
Detailed BPMN 1.1 Weak Points Analysis
Attributes default values
  • BPMN defines mandatory attributes WITH default values
  • XML-Schema does not permit this double assertion
    if an attribute has the default clause defined, it takes the default
    value even if it is not present at all
    use=‘‘optional’’ + default=...

Process
 • BPMN defines Processes as conceptual siblings of the BPD
  • if a Pool shares a Process, then it has one or more Lanes
  • all the other elements are referenced by the Process using their IDs
 !! we don’t want a valid instance with Process as root element
    ∃ Process ⇒ ∃ Pool, but ∃ Pool       ∃ Process
    Process becomes child of Pool



                                                                           18/38
Detailed BPMN 1.1 Weak Points Analysis
Attributes default values
  • BPMN defines mandatory attributes WITH default values
  • XML-Schema does not permit this double assertion
    if an attribute has the default clause defined, it takes the default
    value even if it is not present at all
    use=‘‘optional’’ + default=...

Process
 • BPMN defines Processes as conceptual siblings of the BPD
  • if a Pool shares a Process, then it has one or more Lanes
  • all the other elements are referenced by the Process using their IDs
 !! we don’t want a valid instance with Process as root element
    ∃ Process ⇒ ∃ Pool, but ∃ Pool       ∃ Process
    Process becomes child of Pool



                                                                           18/38
Detailed BPMN 1.1 Weak Points Analysis
Attributes default values
  • BPMN defines mandatory attributes WITH default values
  • XML-Schema does not permit this double assertion
    if an attribute has the default clause defined, it takes the default
    value even if it is not present at all
    use=‘‘optional’’ + default=...

Process
 • BPMN defines Processes as conceptual siblings of the BPD
  • if a Pool shares a Process, then it has one or more Lanes
  • all the other elements are referenced by the Process using their IDs
 !! we don’t want a valid instance with Process as root element
    ∃ Process ⇒ ∃ Pool, but ∃ Pool       ∃ Process
    Process becomes child of Pool



                                                                           18/38
Detailed BPMN 1.1 Weak Points Analysis
Participant




                       • “A Pool represents a Participant”
                         Participant is child of Pool




Message
 • “A Message is the object that is transmitted through a
   MessageFlow”
   Message is child of MessageFlow



                                                             19/38
Detailed BPMN 1.1 Weak Points Analysis
Participant




                       • “A Pool represents a Participant”
                         Participant is child of Pool




Message
 • “A Message is the object that is transmitted through a
   MessageFlow”
   Message is child of MessageFlow



                                                             19/38
Detailed BPMN 1.1 Weak Points Analysis



Web Service
 • WebService is required by many other elements
  • BPMN defines WebService as a Supporting Element
    Inside the BPMN to WS-BPEL mapping example the WebService is
    defined inside the parent element
    We chose to instantiate WebService every time it is needed
    (xs:assert)




                                                                   20/38
Send Task Definition


< xs : complexType name = " SendTaskType " >                                   1
  < xs : complexContent >                                                      2
    < xs : extension base = " bpex : TaskType " >                              3
      < xs : sequence >                                                        4
        < xs : element name = " WebService "                                   5
               type = " bpex : WebServi ceType " minOccurs = " 0 " >           6
          < xs : assert test ="@I mp le m en ta t io n = ‘ Web Service ’"/ >   7
        </ xs : element >                                                      8
      </ xs : sequence >                                                       9
      < xs : attribute name = " MessageRef "                                   10
             type = " bpex : ObjectRef " use = " required " / >                11
      < xs : attribute name = " Impl ementat ion "                             12
             default ="Web Service">                                           13
        < xs : simpleType >                                                    14
        ...                                                                    15


                Listing 1: An excerpt of the Send Task definition




                                                                                    21/38
Detailed BPMN 1.1 Weak Points Analysis


Events
 • XPDL and WS-BPEL define for each Event type a different element
  • complex XML tree
  • BPMN defines only one Event ELEMENT with 3 FAMILIES and
    many different TYPES
    families and types are specifications and not different element
    definitions
    Start, Intermediate and End Event are children of Lane
    (xs:assert)
    we assign a different type based on the Trigger or Result
    attributes values (xs:alternative)




                                                                    22/38
Event Definition
< xs : complexType name = " LaneType " >                                                1
  < xs : complexContent >                                                               2
    < xs : extension base = " bpex : C o m m o n S w i m l a n e T y p e " >            3
      < xs : sequence >                                                                 4
        < xs : element name = " StartEvent "                                            5
               type = " bpex : StartEve ntType "                                        6
               minOccurs = " 0 " maxOccurs = " unbounded " >                            7
          < xs : assert test = " @EventType = ’ Start ’ " / >                           8
        </ xs : element >                                                               9
...                                                                                     10
< xs : complexType name = " StartEve ntType " >                                         11
  < xs : complexContent >                                                               12
    < xs : extension base = " bpex : EventType " >                                      13
      < xs : sequence >                                                                 14
        < xs : element name = " Trigger "                                               15
               type = " bpex : C o m m o n E v e n t D e t a i l T y p e "              16
               minOccurs = " 0 " maxOccurs = " unbounded " >                            17
          < xs : alternative test = " @ E v e n t D e t a i l T y p e = ’ None ’ "      18
                 type = " bpex : N o n e E v e n t D e t a i l T y p e " / >            19
          < xs : alternative test = " @ E v e n t D e t a i l T y p e = ’ Message ’ "   20
                 type = " bpex : M e s s a g e E v e n t D e t a i l T y p e " / >      21
          ...                                                                           22


                    Listing 2: An excerpt of the Events definition



                                                                                             23/38
Detailed BPMN 1.1 Weak Points Analysis


Gateways
 • Gateways can only be detailed in one of the five provided types
 • there is only one element (Gateway) and five possible specifications
 • the Gateway default type is chosen in 2 steps: Exclusive and then
   Data-Based
   we define only one element of type Gateway, child of Lane
   we decide in a second time the Gateway type using
   xs:alternative
   the Gateway default type is chosen in 1 single step: Data-Based
   Exclusive




                                                                        24/38
Gateway Definition



< xs : element name = " Gateway " type = " bpex : C o m m o n G a t e w a y T y p e "        1
                   minOccurs = " 0 " maxOccurs = " unbounded " >                             2
  < xs : alternative                                                                         3
         test = " @GatewayType = ’ Data - Based Exclusive ’ "                                4
         type = " bpex : D a t a B a s e d E x c l u s i v e G a t e w a y T y p e " / >     5
  < xs : alternative                                                                         6
         test = " @GatewayType = ’ Event - Based Exclusive ’ "                               7
         type = " bpex : E v e n t B a s e d E x c l u s i v e G a t e w a y T y p e " / >   8
  < xs : alternative                                                                         9
         test = " @GatewayType = ’ Inclusive ’ "                                             10
         type = " bpex : I n c l u s i v e G a t e w a y T y p e " / >                       11
  ...                                                                                        12


                   Listing 3: An excerpt of the Gateways definition




                                                                                                  25/38
Detailed BPMN 1.1 Weak Points Analysis



Sub-Processes
  • Reusable: Activity which re-calls another Process
     ProcessRef and DiagramRef
  • Reference: it points to another already defined Sub-Process
       SubProcessRef
  • Embedded: it contains a process dependent from the parent process
      the SubProcess elements are defined as Lane children and
    referenced using the GraphicalElements attribute




                                                                        26/38
Detailed BPMN 1.1 Weak Points Analysis
Artifacts
 • one Artifact could be used across the whole BPD, using Associations
    to reference elements
 • they need only one place to be instantiated
    Artifacts as BPD children
    inside the XML they can be positioned everywhere

Transactions and Signals
 • some elements need to be referenced from multiple objects and they
    are instantiated every time they are requested: different IDs but the
    same name
 • the attribute TransactionId of type String serves as an “identifier
    for the Transactions used within a diagram”
    we extended the idea behind the TransactionId also to Signals
    and other similar objects



                                                                           27/38
Detailed BPMN 1.1 Weak Points Analysis
Artifacts
 • one Artifact could be used across the whole BPD, using Associations
    to reference elements
 • they need only one place to be instantiated
    Artifacts as BPD children
    inside the XML they can be positioned everywhere

Transactions and Signals
 • some elements need to be referenced from multiple objects and they
    are instantiated every time they are requested: different IDs but the
    same name
 • the attribute TransactionId of type String serves as an “identifier
    for the Transactions used within a diagram”
    we extended the idea behind the TransactionId also to Signals
    and other similar objects



                                                                           27/38
Referential Integrity Using XPath

  • The very old way: manual ID/IDRef references – strings, numbers,
    NCNames, random generators, . . .
  • The old way: xs:key and xs:keyref
  • The new way: xs:assert and xs:alternative

xs:assert
  • <xs:assert-test=‘‘XPathExpr’’ />
  • limit: the XPath 2.0 expressions set


xs:alternative
  • it permits to choose the type of an element according to the success
    of a XPath 2.0 test
  • useful for Events, Gateways, Activities




                                                                           28/38
Referential Integrity Using XPath

  • The very old way: manual ID/IDRef references – strings, numbers,
    NCNames, random generators, . . .
  • The old way: xs:key and xs:keyref
  • The new way: xs:assert and xs:alternative

xs:assert
  • <xs:assert-test=‘‘XPathExpr’’ />
  • limit: the XPath 2.0 expressions set


xs:alternative
  • it permits to choose the type of an element according to the success
    of a XPath 2.0 test
  • useful for Events, Gateways, Activities




                                                                           28/38
Referential Integrity Verification




• Using our XML-Schema Model we are able to validate statically the
  syntax as well as structural semantics rules of a BPD
• Using a set of XQuery/XPath interrogations on the XML instances
  we can validate also most of the behavioral semantics rules of BPMN
• The use of XQuery/XPath let us verify business rules at code-gen
  time and at run-time




                                                                        29/38
Wrong BPMN Diagram




red: clear (model) errors – orange: hidden (XML) errors




                                                          30/38
Parsing the XML Document




                           31/38
Start Event Check




for $ pool in // Pool ,                                              1
    $ startevent in $ pool // StartEvent                             2
return $ pool // SequenceFlow [ @b pe x :T ar ge t Re f = ←          3
        $ startevent / @bpex:Id ]/ @bpex:Id                          4


      Listing 4: Rules verification using XPath/XQuery: Start Event




                                                                         32/38
Events Number Check



for $ pool in // Pool ,                                                1
$ numSE in count ($ pool // StartEvent ) ,                             2
$ numEE in count ($ pool // EndEvent )                                 3
return if  ($ numSE >0) then                                           4
             if ($ numEE >0) then true () else false ()                5
        else                                                           6
             if ($ numEE =0) then true () else false ()                7


   Listing 5: Rules verification using XPath/XQuery: Events number


“If there is an End (Start) Event, then there MUST be at least one Start
(End) Event”




                                                                           33/38
Instantiation Semantic Verification


for $ pool in // Pool ,                                               1
$ startEvent in $ pool // StartEvent ,                                2
$ numSE in count ($ startEvent ) ,                                    3
$ elements in $ pool / Lane /*[ name ()!= " StartEvent " ]            4
return                                                                5
if ($ numSE >0) then                                                  6
  if ( every $ id in $ elements / @bpex:Id satisfies ←                7
       $ id =$ pool / SequenceFlow / @ b pe x: T ar ge tR e f )       8
  then true ()                                                        9
  else $ elements / @bpex:Id                                          10
else false ()                                                         11


Listing 6: Rules verification using XPath/XQuery: instantiation semantic


“If the Start Event is used, then there MUST NOT be other flow
elements that do not have incoming Sequence Flow”




                                                                           34/38
Comparison with BPMN 2.0


                    BPMN 1.1/1.2   BPMN 2.0     Could our proposal be
                                                still valid?
 Metamodel               Y             Y        With some changes to
                                                be compliant to the
                                                BPMN 2.0 metamodel
 XSD                     N             Y        With some changes
 Referential Int.     Partially     Partially   Y
 Execution               N             Y        Y

To have a simplified core subset of both the BPMN metamodel and the
XML-Schema, compliant to BPMN specifications, is useful to test some
properties, to implement new features, to attempt new strategies, to
implement patches.




                                                                        35/38
Conclusions




What we have talked about

 BPMN 1.1 analysis
 BPMN 2.0 metamodel overview
 Our proposal for a BPMN simplified test-oriented metamodel
 Our proposal for a BPMN XML serialization
 Referential Integrity in BPMN: overview and new approach
 Differences between BPMN 1.1 and BPMN 2.0




                                                             36/38
Further Works



  We are deeply analyzing both the BPMN 2.0 metamodel and its XSD
to get some weaknesses

  We aim to build a tough core subset of the BPMN 2.0 metamodel
deriving, as a consequence, a core subset of the XML-Schema
serialization

   We aim to test some properties over this BPMN Core (maybe the same
Core as defined inside BPMN 2.0 specs) adding some new functionalities
like the validation support at code-gen time.




                                                                        37/38
Thank you.




    Questions?




July 20, 1969 – 22.56 EDT




                            38/38

More Related Content

What's hot

software engineering with uml- activity diagram
software engineering with uml- activity diagramsoftware engineering with uml- activity diagram
software engineering with uml- activity diagram
rahmantoyuri
 
Ultimate guide to_bpmn2_2016_edition_110716
Ultimate guide to_bpmn2_2016_edition_110716Ultimate guide to_bpmn2_2016_edition_110716
Ultimate guide to_bpmn2_2016_edition_110716
yomito_2
 
15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b
guest4c12f7
 
15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b
guest4c12f7
 
15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b
guest4c12f7
 
BPMN by Example
BPMN by ExampleBPMN by Example
BPMN by Example
jonecx
 
Business Process Modeling Notation Fundamentals
Business Process Modeling Notation FundamentalsBusiness Process Modeling Notation Fundamentals
Business Process Modeling Notation Fundamentals
Mustafa Jarrar
 

What's hot (20)

Business Process Model and Notation (BPMN)
Business Process Model and Notation (BPMN)Business Process Model and Notation (BPMN)
Business Process Model and Notation (BPMN)
 
software engineering with uml- activity diagram
software engineering with uml- activity diagramsoftware engineering with uml- activity diagram
software engineering with uml- activity diagram
 
172298
172298172298
172298
 
Ultimate guide to_bpmn2_2016_edition_110716
Ultimate guide to_bpmn2_2016_edition_110716Ultimate guide to_bpmn2_2016_edition_110716
Ultimate guide to_bpmn2_2016_edition_110716
 
Why To Consider BPMN 2.0
Why To Consider BPMN 2.0Why To Consider BPMN 2.0
Why To Consider BPMN 2.0
 
BPMN 2.0 Fundamentals
BPMN 2.0 FundamentalsBPMN 2.0 Fundamentals
BPMN 2.0 Fundamentals
 
15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b
 
15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b
 
15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b15 2 Eleni Pm Lesson 5b
15 2 Eleni Pm Lesson 5b
 
BPMN Process Modeling Levels
BPMN Process Modeling LevelsBPMN Process Modeling Levels
BPMN Process Modeling Levels
 
BPMN Introduction and BPD in Visio
BPMN Introduction and BPD in VisioBPMN Introduction and BPD in Visio
BPMN Introduction and BPD in Visio
 
BPMN by Example
BPMN by ExampleBPMN by Example
BPMN by Example
 
Business Process Modeling Notation Fundamentals
Business Process Modeling Notation FundamentalsBusiness Process Modeling Notation Fundamentals
Business Process Modeling Notation Fundamentals
 
How To Explain BPMN To Business Users
How To Explain BPMN To Business UsersHow To Explain BPMN To Business Users
How To Explain BPMN To Business Users
 
BPMN in Pegasystems' PRPC Flow Rules
BPMN in Pegasystems' PRPC Flow RulesBPMN in Pegasystems' PRPC Flow Rules
BPMN in Pegasystems' PRPC Flow Rules
 
SOA Design Patterns
SOA Design PatternsSOA Design Patterns
SOA Design Patterns
 
2006 mm,ks,jb (miami, florida bpm summit) xpdl tutorial
2006 mm,ks,jb (miami, florida   bpm summit) xpdl tutorial2006 mm,ks,jb (miami, florida   bpm summit) xpdl tutorial
2006 mm,ks,jb (miami, florida bpm summit) xpdl tutorial
 
software design principles
software design principlessoftware design principles
software design principles
 
How to use BPMN* for modelling business processes
How to use BPMN* for modelling business processesHow to use BPMN* for modelling business processes
How to use BPMN* for modelling business processes
 
A methodology for cim modelling and its transformation to pim
A methodology for cim modelling and its transformation to pimA methodology for cim modelling and its transformation to pim
A methodology for cim modelling and its transformation to pim
 

Similar to Modeling and Validating BPMN Diagrams

Bpmn2 modeleruserguide 1.0.1
Bpmn2 modeleruserguide 1.0.1Bpmn2 modeleruserguide 1.0.1
Bpmn2 modeleruserguide 1.0.1
Marcos Santos
 
Adam_Mcconnell_SPR11_v3
Adam_Mcconnell_SPR11_v3Adam_Mcconnell_SPR11_v3
Adam_Mcconnell_SPR11_v3
Adam McConnell
 
Machine learning with Apache Hama
Machine learning with Apache HamaMachine learning with Apache Hama
Machine learning with Apache Hama
Tommaso Teofili
 
FBPM2-Chapter10-ProcessImplementationExecutableModels.pptx
FBPM2-Chapter10-ProcessImplementationExecutableModels.pptxFBPM2-Chapter10-ProcessImplementationExecutableModels.pptx
FBPM2-Chapter10-ProcessImplementationExecutableModels.pptx
ssuser0d0f881
 

Similar to Modeling and Validating BPMN Diagrams (18)

Representing Business Processes: Conceptual Model and Design Methodology
Representing Business Processes: Conceptual Model and Design MethodologyRepresenting Business Processes: Conceptual Model and Design Methodology
Representing Business Processes: Conceptual Model and Design Methodology
 
method_style_ch02.pptx
method_style_ch02.pptxmethod_style_ch02.pptx
method_style_ch02.pptx
 
JBoss Developer Webinar jBPM5
JBoss Developer Webinar jBPM5JBoss Developer Webinar jBPM5
JBoss Developer Webinar jBPM5
 
JBoss jBPM, the future is now for all your Business Processes
JBoss jBPM, the future is now for all your Business ProcessesJBoss jBPM, the future is now for all your Business Processes
JBoss jBPM, the future is now for all your Business Processes
 
JBoss jBPM, the future is now for all your Business Processes by Eric Schabell
JBoss jBPM, the future is now for all your Business Processes by Eric SchabellJBoss jBPM, the future is now for all your Business Processes by Eric Schabell
JBoss jBPM, the future is now for all your Business Processes by Eric Schabell
 
Bpmn2 modeleruserguide 1.0.1
Bpmn2 modeleruserguide 1.0.1Bpmn2 modeleruserguide 1.0.1
Bpmn2 modeleruserguide 1.0.1
 
Adam_Mcconnell_SPR11_v3
Adam_Mcconnell_SPR11_v3Adam_Mcconnell_SPR11_v3
Adam_Mcconnell_SPR11_v3
 
BPMN to UML
BPMN to UMLBPMN to UML
BPMN to UML
 
ch02-part1.pptx
ch02-part1.pptxch02-part1.pptx
ch02-part1.pptx
 
Get your BPM ducks in a row - preparing for migration to jBPM 5
Get your BPM ducks in a row - preparing for migration to jBPM 5Get your BPM ducks in a row - preparing for migration to jBPM 5
Get your BPM ducks in a row - preparing for migration to jBPM 5
 
Final pre power_group_executing bpm processes with Camunda
Final pre power_group_executing bpm processes with CamundaFinal pre power_group_executing bpm processes with Camunda
Final pre power_group_executing bpm processes with Camunda
 
Machine learning with Apache Hama
Machine learning with Apache HamaMachine learning with Apache Hama
Machine learning with Apache Hama
 
Data Parallel and Object Oriented Model
Data Parallel and Object Oriented ModelData Parallel and Object Oriented Model
Data Parallel and Object Oriented Model
 
Couplingand cohesion student
Couplingand cohesion studentCouplingand cohesion student
Couplingand cohesion student
 
jBPM, open source BPM
jBPM, open source BPMjBPM, open source BPM
jBPM, open source BPM
 
[2020 CVPR Efficient DET paper review]
[2020 CVPR Efficient DET paper review][2020 CVPR Efficient DET paper review]
[2020 CVPR Efficient DET paper review]
 
20100223 bpmn
20100223 bpmn20100223 bpmn
20100223 bpmn
 
FBPM2-Chapter10-ProcessImplementationExecutableModels.pptx
FBPM2-Chapter10-ProcessImplementationExecutableModels.pptxFBPM2-Chapter10-ProcessImplementationExecutableModels.pptx
FBPM2-Chapter10-ProcessImplementationExecutableModels.pptx
 

More from Michele Chinosi

More from Michele Chinosi (11)

Babbo Natale va in vacanza?
Babbo Natale va in vacanza?Babbo Natale va in vacanza?
Babbo Natale va in vacanza?
 
BPMN Usage Survey: Tables
BPMN Usage Survey: TablesBPMN Usage Survey: Tables
BPMN Usage Survey: Tables
 
BPMN Usage Survey: Results
BPMN Usage Survey: ResultsBPMN Usage Survey: Results
BPMN Usage Survey: Results
 
Workflow Modeling in EU GENESIS Project
Workflow Modeling in EU GENESIS ProjectWorkflow Modeling in EU GENESIS Project
Workflow Modeling in EU GENESIS Project
 
Modeling Requirements for the Management of Electronic Records
Modeling Requirements for the Management of Electronic RecordsModeling Requirements for the Management of Electronic Records
Modeling Requirements for the Management of Electronic Records
 
Spim Mips Simulator 08 02
Spim Mips Simulator 08 02Spim Mips Simulator 08 02
Spim Mips Simulator 08 02
 
Spim Mips Simulator
Spim Mips SimulatorSpim Mips Simulator
Spim Mips Simulator
 
BPeX: A New Approach to BPMN Model Portability - Updated Version
BPeX: A New Approach to BPMN Model Portability - Updated VersionBPeX: A New Approach to BPMN Model Portability - Updated Version
BPeX: A New Approach to BPMN Model Portability - Updated Version
 
Integrating Privacy Policies into Business Processes
Integrating Privacy Policies into Business ProcessesIntegrating Privacy Policies into Business Processes
Integrating Privacy Policies into Business Processes
 
Novelle: A collaborative open source writing tool software
Novelle: A collaborative open source writing tool softwareNovelle: A collaborative open source writing tool software
Novelle: A collaborative open source writing tool software
 
BPeX: A New Approach to BPMN Model Portability
BPeX: A New Approach to BPMN Model PortabilityBPeX: A New Approach to BPMN Model Portability
BPeX: A New Approach to BPMN Model Portability
 

Recently uploaded

如何办理(SUT毕业证书)斯威本科技大学毕业证成绩单本科硕士学位证留信学历认证
如何办理(SUT毕业证书)斯威本科技大学毕业证成绩单本科硕士学位证留信学历认证如何办理(SUT毕业证书)斯威本科技大学毕业证成绩单本科硕士学位证留信学历认证
如何办理(SUT毕业证书)斯威本科技大学毕业证成绩单本科硕士学位证留信学历认证
ogawka
 
一比一原版(USYD毕业证书)悉尼大学毕业证原件一模一样
一比一原版(USYD毕业证书)悉尼大学毕业证原件一模一样一比一原版(USYD毕业证书)悉尼大学毕业证原件一模一样
一比一原版(USYD毕业证书)悉尼大学毕业证原件一模一样
AS
 
Abortion pills in Muscut<Oman(+27737758557) Cytotec available.inn Kuwait City.
Abortion pills in Muscut<Oman(+27737758557) Cytotec available.inn Kuwait City.Abortion pills in Muscut<Oman(+27737758557) Cytotec available.inn Kuwait City.
Abortion pills in Muscut<Oman(+27737758557) Cytotec available.inn Kuwait City.
daisycvs
 
Powerpoint showing results from tik tok metrics
Powerpoint showing results from tik tok metricsPowerpoint showing results from tik tok metrics
Powerpoint showing results from tik tok metrics
CaitlinCummins3
 
Jual Obat Aborsi Di Sibolga wa 0851/7541/5434 Cytotec Misoprostol 200mcg Pfizer
Jual Obat Aborsi Di Sibolga wa 0851/7541/5434 Cytotec Misoprostol 200mcg PfizerJual Obat Aborsi Di Sibolga wa 0851/7541/5434 Cytotec Misoprostol 200mcg Pfizer
Jual Obat Aborsi Di Sibolga wa 0851/7541/5434 Cytotec Misoprostol 200mcg Pfizer
Pusat Herbal Resmi BPOM
 
What is paper chromatography, principal, procedure,types, diagram, advantages...
What is paper chromatography, principal, procedure,types, diagram, advantages...What is paper chromatography, principal, procedure,types, diagram, advantages...
What is paper chromatography, principal, procedure,types, diagram, advantages...
srcw2322l101
 

Recently uploaded (20)

South Africa's 10 Most Influential CIOs to Watch.pdf
South Africa's 10 Most Influential CIOs to Watch.pdfSouth Africa's 10 Most Influential CIOs to Watch.pdf
South Africa's 10 Most Influential CIOs to Watch.pdf
 
MichaelStarkes_UncutGemsProjectSummary.pdf
MichaelStarkes_UncutGemsProjectSummary.pdfMichaelStarkes_UncutGemsProjectSummary.pdf
MichaelStarkes_UncutGemsProjectSummary.pdf
 
如何办理(SUT毕业证书)斯威本科技大学毕业证成绩单本科硕士学位证留信学历认证
如何办理(SUT毕业证书)斯威本科技大学毕业证成绩单本科硕士学位证留信学历认证如何办理(SUT毕业证书)斯威本科技大学毕业证成绩单本科硕士学位证留信学历认证
如何办理(SUT毕业证书)斯威本科技大学毕业证成绩单本科硕士学位证留信学历认证
 
一比一原版(USYD毕业证书)悉尼大学毕业证原件一模一样
一比一原版(USYD毕业证书)悉尼大学毕业证原件一模一样一比一原版(USYD毕业证书)悉尼大学毕业证原件一模一样
一比一原版(USYD毕业证书)悉尼大学毕业证原件一模一样
 
How to refresh to be fit for the future world
How to refresh to be fit for the future worldHow to refresh to be fit for the future world
How to refresh to be fit for the future world
 
High Profile Bangalore Just VIP Brigade Road 100% Genuine at your Door Step
High Profile Bangalore Just VIP Brigade Road 100% Genuine at your Door StepHigh Profile Bangalore Just VIP Brigade Road 100% Genuine at your Door Step
High Profile Bangalore Just VIP Brigade Road 100% Genuine at your Door Step
 
Toyota Kata Coaching for Agile Teams & Transformations
Toyota Kata Coaching for Agile Teams & TransformationsToyota Kata Coaching for Agile Teams & Transformations
Toyota Kata Coaching for Agile Teams & Transformations
 
Home Furnishings Ecommerce Platform Short Pitch 2024
Home Furnishings Ecommerce Platform Short Pitch 2024Home Furnishings Ecommerce Platform Short Pitch 2024
Home Furnishings Ecommerce Platform Short Pitch 2024
 
Abortion pills in Muscut<Oman(+27737758557) Cytotec available.inn Kuwait City.
Abortion pills in Muscut<Oman(+27737758557) Cytotec available.inn Kuwait City.Abortion pills in Muscut<Oman(+27737758557) Cytotec available.inn Kuwait City.
Abortion pills in Muscut<Oman(+27737758557) Cytotec available.inn Kuwait City.
 
stock price prediction using machine learning
stock price prediction using machine learningstock price prediction using machine learning
stock price prediction using machine learning
 
wagamamaLab presentation @MIT 20240509 IRODORI
wagamamaLab presentation @MIT 20240509 IRODORIwagamamaLab presentation @MIT 20240509 IRODORI
wagamamaLab presentation @MIT 20240509 IRODORI
 
Moradia Isolada com Logradouro; Detached house with patio in Penacova
Moradia Isolada com Logradouro; Detached house with patio in PenacovaMoradia Isolada com Logradouro; Detached house with patio in Penacova
Moradia Isolada com Logradouro; Detached house with patio in Penacova
 
hyundai capital 2023 consolidated financial statements
hyundai capital 2023 consolidated financial statementshyundai capital 2023 consolidated financial statements
hyundai capital 2023 consolidated financial statements
 
Powerpoint showing results from tik tok metrics
Powerpoint showing results from tik tok metricsPowerpoint showing results from tik tok metrics
Powerpoint showing results from tik tok metrics
 
Jual Obat Aborsi Di Sibolga wa 0851/7541/5434 Cytotec Misoprostol 200mcg Pfizer
Jual Obat Aborsi Di Sibolga wa 0851/7541/5434 Cytotec Misoprostol 200mcg PfizerJual Obat Aborsi Di Sibolga wa 0851/7541/5434 Cytotec Misoprostol 200mcg Pfizer
Jual Obat Aborsi Di Sibolga wa 0851/7541/5434 Cytotec Misoprostol 200mcg Pfizer
 
tekAura | Desktop Procedure Template (2016)
tekAura | Desktop Procedure Template (2016)tekAura | Desktop Procedure Template (2016)
tekAura | Desktop Procedure Template (2016)
 
Should Law Firms Outsource their Bookkeeping
Should Law Firms Outsource their BookkeepingShould Law Firms Outsource their Bookkeeping
Should Law Firms Outsource their Bookkeeping
 
First Time Home Buyer's Guide - KM Realty Group LLC
First Time Home Buyer's Guide - KM Realty Group LLCFirst Time Home Buyer's Guide - KM Realty Group LLC
First Time Home Buyer's Guide - KM Realty Group LLC
 
What is paper chromatography, principal, procedure,types, diagram, advantages...
What is paper chromatography, principal, procedure,types, diagram, advantages...What is paper chromatography, principal, procedure,types, diagram, advantages...
What is paper chromatography, principal, procedure,types, diagram, advantages...
 
Pitch Deck Teardown: Goodcarbon's $5.5m Seed deck
Pitch Deck Teardown: Goodcarbon's $5.5m Seed deckPitch Deck Teardown: Goodcarbon's $5.5m Seed deck
Pitch Deck Teardown: Goodcarbon's $5.5m Seed deck
 

Modeling and Validating BPMN Diagrams

  • 1. Modeling and Validating BPMN Diagrams Michele Chinosi, Alberto Trombetta Universit` degli Studi dell’Insubria (Varese – Italy) a Dipartimento di Informatica e Comunicazione michele.chinosi@uninsubria.it BPMN 2009 Workshop July 20, 2009, Vienna, Austria
  • 3. Agenda BPMN 1.1 and 2.0 Analysis Our BPMN Metamodel Proposal The XML Linearization Referential Integrity Concluding Remarks 3/38
  • 4. Motivations • need for easy usable models to test properties, to patch BPMN and to add new features • other proposals (as well as BPMN 2.0 submissions) are quite unclear and too complex • lack of validation support • BPMN 1.1/1.2 comes without a native XSD • methods to ensure diagrams correctness are manual and error-prone 4/38
  • 5. Contributions • simplified test-oriented version of the BPMN metamodel • self-validating XML serialization for BPMN diagrams • automated checks (using software tools) • our approach could be abstracted from the specificities of BPMN 1.2 porting the base concepts also to BPMN 2.0 Last-Month Update This work has been partially superseded by the recent BPMN 2.0 final submission adoption by OMG. We will see a brief summary of major changes at the end of this talk. 5/38
  • 6. Contributions • simplified test-oriented version of the BPMN metamodel • self-validating XML serialization for BPMN diagrams • automated checks (using software tools) • our approach could be abstracted from the specificities of BPMN 1.2 porting the base concepts also to BPMN 2.0 Last-Month Update This work has been partially superseded by the recent BPMN 2.0 final submission adoption by OMG. We will see a brief summary of major changes at the end of this talk. 5/38
  • 7. BPMN 1.1 Weak Points Analysis • weak hierarchical structure of the model • BPD are strongly hierarchical • elements placement inside the model does not reflect the expected placement inside the diagram • UML metamodel uses only generalization connections • no valid/meaningful instances • lack of distinctions between several elements and types definitions • they are all elements (classes) • Connections-by-Types 6/38
  • 8. Sketch of BPMN 1.1 Metamodel 7/38
  • 10. BPMN 2.0 Overview (B)IOS • (BEA), IBM, Oracle, SAP • execution semantics formalization • extensibility mechanism for both model and graphical extensions • event composition and correlation refinement • human interactions definition • choreography model BPMN-S • Adaptive, Axway Software, HP, Lombardi Software, Fujitsu, et al. • business level modeling • checking compliance to choreography and rules • process taxonomies • execution interoperability • model re-usability 9/38
  • 11. Sketch of BPMN 2.0 UML – (B)IOS Proposal 10/38
  • 12. Sketch of BPMN 2.0 UML – BPMN-S Proposal 11/38
  • 13. Sketch of BPMN 2.0 UML – Final Submission 12/38
  • 14. BPMN 2.0 – The CORE UML Class Diagram Example 13/38
  • 15. BPMN 2.0 – The Package Diagram Example 14/38
  • 16. Our BPMN 1.1 Metamodel Proposal • top-down fashion methodology • from BPD to all the other elements • strongly hierarchical model • reduces the Connections-by-Types and deletes all the missing connections • BPMN Supporting elements treated as types • simpler model • Connections-by-Semantics (UML compositions) • every BPD can be described as one valid instance of the model • right positioning of Connecting flow objects 15/38
  • 17. Sketch of our BPMN 1.1 Metamodel Proposal 16/38
  • 18. The XML Linearization BPMN ⊃ WS-BPEL Still incomplete ⇒ BPMN 2.0 ⇒ and BPMN = XPDL Complex could be adapted to become BPMN 1.1 → XML −−−−−−−−−−− −−−−−−−−−−→ ⊆ BPMN 2.0 • Our linearization proposal could be useful to study diagram and/or model properties and to make some tests, as well as to validate both a model and its instances. 17/38
  • 19. The XML Linearization BPMN ⊃ WS-BPEL Still incomplete ⇒ BPMN 2.0 ⇒ and BPMN = XPDL Complex could be adapted to become BPMN 1.1 → XML −−−−−−−−−−− −−−−−−−−−−→ ⊆ BPMN 2.0 • Our linearization proposal could be useful to study diagram and/or model properties and to make some tests, as well as to validate both a model and its instances. 17/38
  • 20. Detailed BPMN 1.1 Weak Points Analysis Attributes default values • BPMN defines mandatory attributes WITH default values • XML-Schema does not permit this double assertion if an attribute has the default clause defined, it takes the default value even if it is not present at all use=‘‘optional’’ + default=... Process • BPMN defines Processes as conceptual siblings of the BPD • if a Pool shares a Process, then it has one or more Lanes • all the other elements are referenced by the Process using their IDs !! we don’t want a valid instance with Process as root element ∃ Process ⇒ ∃ Pool, but ∃ Pool ∃ Process Process becomes child of Pool 18/38
  • 21. Detailed BPMN 1.1 Weak Points Analysis Attributes default values • BPMN defines mandatory attributes WITH default values • XML-Schema does not permit this double assertion if an attribute has the default clause defined, it takes the default value even if it is not present at all use=‘‘optional’’ + default=... Process • BPMN defines Processes as conceptual siblings of the BPD • if a Pool shares a Process, then it has one or more Lanes • all the other elements are referenced by the Process using their IDs !! we don’t want a valid instance with Process as root element ∃ Process ⇒ ∃ Pool, but ∃ Pool ∃ Process Process becomes child of Pool 18/38
  • 22. Detailed BPMN 1.1 Weak Points Analysis Attributes default values • BPMN defines mandatory attributes WITH default values • XML-Schema does not permit this double assertion if an attribute has the default clause defined, it takes the default value even if it is not present at all use=‘‘optional’’ + default=... Process • BPMN defines Processes as conceptual siblings of the BPD • if a Pool shares a Process, then it has one or more Lanes • all the other elements are referenced by the Process using their IDs !! we don’t want a valid instance with Process as root element ∃ Process ⇒ ∃ Pool, but ∃ Pool ∃ Process Process becomes child of Pool 18/38
  • 23. Detailed BPMN 1.1 Weak Points Analysis Attributes default values • BPMN defines mandatory attributes WITH default values • XML-Schema does not permit this double assertion if an attribute has the default clause defined, it takes the default value even if it is not present at all use=‘‘optional’’ + default=... Process • BPMN defines Processes as conceptual siblings of the BPD • if a Pool shares a Process, then it has one or more Lanes • all the other elements are referenced by the Process using their IDs !! we don’t want a valid instance with Process as root element ∃ Process ⇒ ∃ Pool, but ∃ Pool ∃ Process Process becomes child of Pool 18/38
  • 24. Detailed BPMN 1.1 Weak Points Analysis Participant • “A Pool represents a Participant” Participant is child of Pool Message • “A Message is the object that is transmitted through a MessageFlow” Message is child of MessageFlow 19/38
  • 25. Detailed BPMN 1.1 Weak Points Analysis Participant • “A Pool represents a Participant” Participant is child of Pool Message • “A Message is the object that is transmitted through a MessageFlow” Message is child of MessageFlow 19/38
  • 26. Detailed BPMN 1.1 Weak Points Analysis Web Service • WebService is required by many other elements • BPMN defines WebService as a Supporting Element Inside the BPMN to WS-BPEL mapping example the WebService is defined inside the parent element We chose to instantiate WebService every time it is needed (xs:assert) 20/38
  • 27. Send Task Definition < xs : complexType name = " SendTaskType " > 1 < xs : complexContent > 2 < xs : extension base = " bpex : TaskType " > 3 < xs : sequence > 4 < xs : element name = " WebService " 5 type = " bpex : WebServi ceType " minOccurs = " 0 " > 6 < xs : assert test ="@I mp le m en ta t io n = ‘ Web Service ’"/ > 7 </ xs : element > 8 </ xs : sequence > 9 < xs : attribute name = " MessageRef " 10 type = " bpex : ObjectRef " use = " required " / > 11 < xs : attribute name = " Impl ementat ion " 12 default ="Web Service"> 13 < xs : simpleType > 14 ... 15 Listing 1: An excerpt of the Send Task definition 21/38
  • 28. Detailed BPMN 1.1 Weak Points Analysis Events • XPDL and WS-BPEL define for each Event type a different element • complex XML tree • BPMN defines only one Event ELEMENT with 3 FAMILIES and many different TYPES families and types are specifications and not different element definitions Start, Intermediate and End Event are children of Lane (xs:assert) we assign a different type based on the Trigger or Result attributes values (xs:alternative) 22/38
  • 29. Event Definition < xs : complexType name = " LaneType " > 1 < xs : complexContent > 2 < xs : extension base = " bpex : C o m m o n S w i m l a n e T y p e " > 3 < xs : sequence > 4 < xs : element name = " StartEvent " 5 type = " bpex : StartEve ntType " 6 minOccurs = " 0 " maxOccurs = " unbounded " > 7 < xs : assert test = " @EventType = ’ Start ’ " / > 8 </ xs : element > 9 ... 10 < xs : complexType name = " StartEve ntType " > 11 < xs : complexContent > 12 < xs : extension base = " bpex : EventType " > 13 < xs : sequence > 14 < xs : element name = " Trigger " 15 type = " bpex : C o m m o n E v e n t D e t a i l T y p e " 16 minOccurs = " 0 " maxOccurs = " unbounded " > 17 < xs : alternative test = " @ E v e n t D e t a i l T y p e = ’ None ’ " 18 type = " bpex : N o n e E v e n t D e t a i l T y p e " / > 19 < xs : alternative test = " @ E v e n t D e t a i l T y p e = ’ Message ’ " 20 type = " bpex : M e s s a g e E v e n t D e t a i l T y p e " / > 21 ... 22 Listing 2: An excerpt of the Events definition 23/38
  • 30. Detailed BPMN 1.1 Weak Points Analysis Gateways • Gateways can only be detailed in one of the five provided types • there is only one element (Gateway) and five possible specifications • the Gateway default type is chosen in 2 steps: Exclusive and then Data-Based we define only one element of type Gateway, child of Lane we decide in a second time the Gateway type using xs:alternative the Gateway default type is chosen in 1 single step: Data-Based Exclusive 24/38
  • 31. Gateway Definition < xs : element name = " Gateway " type = " bpex : C o m m o n G a t e w a y T y p e " 1 minOccurs = " 0 " maxOccurs = " unbounded " > 2 < xs : alternative 3 test = " @GatewayType = ’ Data - Based Exclusive ’ " 4 type = " bpex : D a t a B a s e d E x c l u s i v e G a t e w a y T y p e " / > 5 < xs : alternative 6 test = " @GatewayType = ’ Event - Based Exclusive ’ " 7 type = " bpex : E v e n t B a s e d E x c l u s i v e G a t e w a y T y p e " / > 8 < xs : alternative 9 test = " @GatewayType = ’ Inclusive ’ " 10 type = " bpex : I n c l u s i v e G a t e w a y T y p e " / > 11 ... 12 Listing 3: An excerpt of the Gateways definition 25/38
  • 32. Detailed BPMN 1.1 Weak Points Analysis Sub-Processes • Reusable: Activity which re-calls another Process ProcessRef and DiagramRef • Reference: it points to another already defined Sub-Process SubProcessRef • Embedded: it contains a process dependent from the parent process the SubProcess elements are defined as Lane children and referenced using the GraphicalElements attribute 26/38
  • 33. Detailed BPMN 1.1 Weak Points Analysis Artifacts • one Artifact could be used across the whole BPD, using Associations to reference elements • they need only one place to be instantiated Artifacts as BPD children inside the XML they can be positioned everywhere Transactions and Signals • some elements need to be referenced from multiple objects and they are instantiated every time they are requested: different IDs but the same name • the attribute TransactionId of type String serves as an “identifier for the Transactions used within a diagram” we extended the idea behind the TransactionId also to Signals and other similar objects 27/38
  • 34. Detailed BPMN 1.1 Weak Points Analysis Artifacts • one Artifact could be used across the whole BPD, using Associations to reference elements • they need only one place to be instantiated Artifacts as BPD children inside the XML they can be positioned everywhere Transactions and Signals • some elements need to be referenced from multiple objects and they are instantiated every time they are requested: different IDs but the same name • the attribute TransactionId of type String serves as an “identifier for the Transactions used within a diagram” we extended the idea behind the TransactionId also to Signals and other similar objects 27/38
  • 35. Referential Integrity Using XPath • The very old way: manual ID/IDRef references – strings, numbers, NCNames, random generators, . . . • The old way: xs:key and xs:keyref • The new way: xs:assert and xs:alternative xs:assert • <xs:assert-test=‘‘XPathExpr’’ /> • limit: the XPath 2.0 expressions set xs:alternative • it permits to choose the type of an element according to the success of a XPath 2.0 test • useful for Events, Gateways, Activities 28/38
  • 36. Referential Integrity Using XPath • The very old way: manual ID/IDRef references – strings, numbers, NCNames, random generators, . . . • The old way: xs:key and xs:keyref • The new way: xs:assert and xs:alternative xs:assert • <xs:assert-test=‘‘XPathExpr’’ /> • limit: the XPath 2.0 expressions set xs:alternative • it permits to choose the type of an element according to the success of a XPath 2.0 test • useful for Events, Gateways, Activities 28/38
  • 37. Referential Integrity Verification • Using our XML-Schema Model we are able to validate statically the syntax as well as structural semantics rules of a BPD • Using a set of XQuery/XPath interrogations on the XML instances we can validate also most of the behavioral semantics rules of BPMN • The use of XQuery/XPath let us verify business rules at code-gen time and at run-time 29/38
  • 38. Wrong BPMN Diagram red: clear (model) errors – orange: hidden (XML) errors 30/38
  • 39. Parsing the XML Document 31/38
  • 40. Start Event Check for $ pool in // Pool , 1 $ startevent in $ pool // StartEvent 2 return $ pool // SequenceFlow [ @b pe x :T ar ge t Re f = ← 3 $ startevent / @bpex:Id ]/ @bpex:Id 4 Listing 4: Rules verification using XPath/XQuery: Start Event 32/38
  • 41. Events Number Check for $ pool in // Pool , 1 $ numSE in count ($ pool // StartEvent ) , 2 $ numEE in count ($ pool // EndEvent ) 3 return if ($ numSE >0) then 4 if ($ numEE >0) then true () else false () 5 else 6 if ($ numEE =0) then true () else false () 7 Listing 5: Rules verification using XPath/XQuery: Events number “If there is an End (Start) Event, then there MUST be at least one Start (End) Event” 33/38
  • 42. Instantiation Semantic Verification for $ pool in // Pool , 1 $ startEvent in $ pool // StartEvent , 2 $ numSE in count ($ startEvent ) , 3 $ elements in $ pool / Lane /*[ name ()!= " StartEvent " ] 4 return 5 if ($ numSE >0) then 6 if ( every $ id in $ elements / @bpex:Id satisfies ← 7 $ id =$ pool / SequenceFlow / @ b pe x: T ar ge tR e f ) 8 then true () 9 else $ elements / @bpex:Id 10 else false () 11 Listing 6: Rules verification using XPath/XQuery: instantiation semantic “If the Start Event is used, then there MUST NOT be other flow elements that do not have incoming Sequence Flow” 34/38
  • 43. Comparison with BPMN 2.0 BPMN 1.1/1.2 BPMN 2.0 Could our proposal be still valid? Metamodel Y Y With some changes to be compliant to the BPMN 2.0 metamodel XSD N Y With some changes Referential Int. Partially Partially Y Execution N Y Y To have a simplified core subset of both the BPMN metamodel and the XML-Schema, compliant to BPMN specifications, is useful to test some properties, to implement new features, to attempt new strategies, to implement patches. 35/38
  • 44. Conclusions What we have talked about BPMN 1.1 analysis BPMN 2.0 metamodel overview Our proposal for a BPMN simplified test-oriented metamodel Our proposal for a BPMN XML serialization Referential Integrity in BPMN: overview and new approach Differences between BPMN 1.1 and BPMN 2.0 36/38
  • 45. Further Works We are deeply analyzing both the BPMN 2.0 metamodel and its XSD to get some weaknesses We aim to build a tough core subset of the BPMN 2.0 metamodel deriving, as a consequence, a core subset of the XML-Schema serialization We aim to test some properties over this BPMN Core (maybe the same Core as defined inside BPMN 2.0 specs) adding some new functionalities like the validation support at code-gen time. 37/38
  • 46. Thank you. Questions? July 20, 1969 – 22.56 EDT 38/38