Title: Dynamic Workflow Modeling and Analysis
1Dynamic Workflow Modeling and Analysis
- J. Wang and R. Rosca
- Department of Software Engineering
- Monmouth University
2Outline
- Motivation
- An intuitive and formal workflow model
- Well-formed workflows
- Verification
- Tool support
- Conclusion and future work
3Motivation
- Driven by workflow design for incident command
systems - Frequent changes of the course of action dictated
by incoming events - Calls for on-the-fly verification of the workflow
correctness - Predominantly volunteer-based workforce
- Needs intuitive features for the description and
modification of the WF - High stake
- Needs formal approach (no ambiguity, allows
analysis) - We introduced the Workflow Intuitive Formal
Approach (WIFA) to meet the needs
4WIFA Workflow Definition
- A workflow is WF (T, P, C, A, S0), where
- T T1, T2, Tm is a set of tasks, m 1.
- P (p)mxm is the precedence matrix of the task
set. If Ti is the direct predecessor of Tj, then
pij 1 otherwise, pij 0. - C (c)mxm is the conflict matrix of the task
set. cij ? 0, 1 for i 1, 2, m and j 1, 2,
m. - A (A(T1), A(T2), , A(Tm)) defines
pre-condition set for each task. ?Tk ? T, A(Tk)
Tk ? . Let set A ? A(Tk). Then Ti ? A
implies pik 1. - S0 ? 0, 1, 2, 3m is the initial state of the
workflow.
5Example
T T1, T2, , T8,
A(T1) Ø, A(T2) T1, T6, A(T3) T1,
A(T4) T2, A(T5) T4, A(T6) A(T7)
T5, A(T8) T3, T7. S0 (1, 0, 0, 0, 0,
0, 0, 0).
,
6Individual Task State Values
- S(Ti) 0 means Ti is not executable at state S
and not executed previously. - S(Ti) 1 means Ti is executable at state S and
not executed previously. - S(Ti) 2 means Ti is not executable at state S
and executed previously. - S(Ti) 3 means Ti is executable at state S and
executed previously.
7State Transition Rules
- A set of rules to guide workflow execution
- Denote by Sa(Ti)Sb that task Ti is executed under
state Sa, and the new state after the execution
is Sb. - Rules ? Tj ? T,
- If Tj Ti then Sb(Tj) 2. (Tj is just executed)
- If Sa(Tj) 0
- If pij 1 and ?A ? A(Tj) such that Sb(Tk) 2
for any Tk ?A, then Sb(Tj) 1 - otherwise Sb(Tj) 0.
8State Transition Rules
- Sa(Tj) 1
- If cij 0 then Sb(Tj) 1 otherwise Sb(Tj) 0.
- Sa(Tj) 2
- If pij 1 and ?A ? A(Tj) such that Sb(Tk) 2
for any Tk ?A, then Sb(Tj) 3 otherwise Sb(Tj)
2. - Sa(Tj) 3
- If cij 0 then Sb(Tj) 3 otherwise Sb(Tj) 2.
State value change of a task
9State Transition Rules
T4
T2
T5
T7
T1
c23 1
T6
T3
S0 (1, 0, 0, 0, 0, 0, 0) S1 (2, 1, 1, 0, 0, 0,
0) S2 (2, 2, 0, 1, 0, 0, 0) S3 (2, 0, 2, 0, 0,
1, 0)
10Modeling Power
- Sequential execution
- Conflict (decision making)
- Concurrency
- Synchronization
- Loop
c23 0 c67 1 A(T2) T1,T2 A(T8) T3,
T7
11Reachability Tree
12Well-Formed Workflows
- All reachable states form reachable set R
- A workflow is well-formed if and only if the
following two behavior conditions are met - There is no dangling task
- Given any reachable state, there is always an
execution path leading the workflow to finish - Validation of a WF being well-formed requires the
reachability analysis of the WF
13Confusion-Free Workflows
- To simplify workflow modeling and verification
- A confusion-free workflow
- Is a well-formed workflow
- Either all tasks triggered by the same task are
in conflict, or no pairs of them are in conflict - A task becomes executable either when all of its
predecessor tasks are executed, or when any one
of them is executed
XOR-In-and-Out
AND-In-AND-Out
AND-In-XOR-Out
XOR-In-XOR-Out
14Workflow Dynamics
- A couple of theorems developed for quick
on-the-fly well-formedness verification - Theorem for adding new tasks to a WF, such that
the new WF can preserve the confusion-free,
well-formed properties (in the paper). - Theorem for deleting a task from the WF such that
the new WF can preserve the confusion-free,
well-formed properties. - Theorems for changing business rules that express
task dependencies
15Lemma 1
- Given a workflow WFA (T, P, C, A, S0) with Tk ?
T. As shown in Fig, WFB (T, P, C, A, S0)
is obtained by replacing Tk with Tk1 and Tk2,
such that - Tk1 Tk, Tk2 Tk, Tk1 Tk2 and Tk2
Tk1, - A (Tk1) A(Tk)
- C(Ti, Tj) C(Ti, Tj) for ?Ti, Tj ? Tk,
- Then WFB is confusion-free well-formed iff WFA is
confusion-free well-formed.
16Lemma 2
- Let WFA (T, P, C, A, S0) be a well-formed
confusion-free workflow with Tk1, Tk2 ? T, Tk1
Tk2 ?, and Tk2 is not a predecessor of Tk1.
As shown in the figure, WFB (T, P, C, A,
S0) is obtained by introducing precedence
constraint between Tk1 and Tk2 such that Tk1 is
an immediate predecessor of Tk2. Then WFB is also
well-formed and confusion-free.
17Adding a new task
Tk
Ti
WF
Tk
Ti
Tk
Tk ? ?, Tk ?
WF
Tk ?, Tk ? ?
WF
Tk ? ?, Tk ? ?
18Changing dependency
T6
T3
T5
T4
T8
T7
T1
T2
19Deleting a task
20Tool Support for Editing, Validation and
Enactment of WFs
21Tool Features
- Saving workflow in XML or as an image
- Drag and Drop interface
- Dynamically change tasks/workflow properties
- Zooming in and out to focus on specific sections
of the workflow - Validate workflow
- Visually step through workflow in design window
- Step forward/backward through the simulation
- Auto-play speed adjustment
- Audit log for post incident analysis
22Conclusion
- Introduced a new formalism to support dynamic
workflow modeling and verification - Developed a set of theorems to validate the
on-the-fly workflow changes - Implemented a tool to allow easy workflow
construction, modification, verification and
execution
23Future Work
- Data dependency
- Decision support
- Inter-organizational workflows
- Tool enhancement