Title: New insights on architectural connectors
1New insights on architectural connectors
IFIP TCS 2004, Toulouse, 22-27 August 2004
Ivan Lanese Computer Science Department
University of Pisa
joint work with Roberto Bruni University of
Pisa, Italy Ugo Montanari University of
Pisa, Italy José Luiz Fiadeiro University of
Leicester, UK Antónia Lopes University of
Lisbon, Portugal
2Roadmap
- Goal
- Background CommUnity
- Background tile logic
- Standard decomposition for CommUnity
- From CommUnity to tiles
- Conclusion and future work
3Roadmap
- Goal
- Background CommUnity
- Background tile logic
- Standard decomposition for CommUnity
- From CommUnity to tiles
- Conclusion and future work
4General motivation I
- Comparing the categorical and the algebraic
approach to systems - Categorical approach
- Algebraic approach
5General motivation II
- Comparing the categorical and the algebraic
approach to systems - Categorical approach
- objects are system components
- morphisms express simulation, refinement,
- complex systems are modeled as diagrams
- composition via universal construction (colimit)
- Algebraic approach
6General motivation III
- Comparing the categorical and the algebraic
approach to systems - Categorical approach
- Algebraic approach
- System represented by an algebra
- constants are basic components
- operations compose smaller systems into larger
ones - structural axioms collapse structurally
equivalent systems - operational semantics (SOS style)
- abstract semantics (bisimilarity)
7Specific aim
- Reconcile two selected representatives
- CommUnity (categorical)
- architectural description language
- distinction between computation and coordination
- Tile model (algebraic)
- operational model for concurrent systems
- co-existence of horizontal (space) and vertical
(time) dimensions
8Specific aim advantages
- Advantage transfer of concepts and techniques
- Semantic model for CommUnity
- Observational equivalence of CommUnity
configurations - CommUnity-like connectors in the tile model
- Separation between computation and coordination
for tiles
9Roadmap
- Goal
- Background CommUnity
- Background tile logic
- Standard decomposition for CommUnity
- From CommUnity to tiles
- Conclusion and future work
10CommUnity
- System configurations are diagrams
- Components compute locally
- Interactions as architectural connectors
Denotational semantics
Program
11CommUnity programs
design foo is in x, z out v, n do a true ?
v xz nvx b ngtMIN ? nn-x c
vltMAX ? vnz
input/output channels
12Morphisms
output channels cannot be merged
P1
channels of P1 to channels of P2
(names are not important)
actions of P2 to actions of P1
actions of P1 correspond to disjoint sets of
actions of P2
P2
13Example
design P1 is in out do a b
design P is in out do fap faq
far gap gaq gar
hbs
f,g ? a ? p,q,r h ? b ? s
design P2 is in out do f g h
design P3 is in out do p q r
s
14Star-shaped diagrams
glue
cables no output channels actions are true? skip
roles
15Roadmap
- Goal
- Background CommUnity
- Background tile logic
- Standard decomposition for CommUnity
- From CommUnity to tiles
- Conclusion and future work
16Tile model
- Operational and abstract semantics of open
concurrent systems - Compositional in space and time
- Deals uniformly with closed and open systems
- Congruence results for particular formats
- Category based but compositionality dealt with
algebraic methods
17Configurations
output interface
input interface
(interfaces can be typed)
18Configurations
output interface
input interface
parallel composition
symmetries
sequential composition
19Observations
initial interface
final interface
20Tiles
- Combine horizontal and vertical structures
through interfaces
21Tiles
- Compose tiles
- horizontally
22Tiles
- Compose tiles
- horizontally
- (also vertically and in parallel)
23Operational semantics
- Structural equivalence
- Axioms on configurations (e.g. symmetries)
- LTS
- states configurations
- transitions tiles
- labels (trigger,effect) pairs
24Abstract semantics
- Tile bisimilarity
- Standard bisimilarity applied to previous
transition system - Systems are bisimilar iff they can mutually
simulate transitions - More powerful than trace equivalence
25Roadmap
- Goal
- Background CommUnity
- Background tile logic
- Standard decomposition for CommUnity
- From CommUnity to tiles
- Conclusion and future work
26Standard decomposition
- The decomposition of a program is a star-shaped
diagram - It highlights the algebraic structure of
CommUnity programs - It is the first step of the translation into the
tile model
27Standard decomposition illustrated
- n output channels
- m actions
P
- n channel managers
- m guard managers
- nm cables
- 1 glue
28Elements of the decomposition
- Glue
- Channel managers
- Guard managers
- Cables
- Morphisms
29Elements of the decomposition
- Glue
- all the channels as input channels
- all the actions as true ? skip
- Channel managers
- Guard managers
- Cables
- Morphisms
30Elements of the decomposition
- Glue
- Channel managers
- one for each output channel
- the assignments to that channel as actions
- the input channels needed to evaluate the
assignments - Guard managers
- Cables
- Morphisms
31Elements of the decomposition
- Glue
- Channel managers
- Guard managers
- one for each guard
- one action of the form pred ? skip
- the input channels needed to evaluate the guard
- Cables
- Morphisms
32Elements of the decomposition
- Glue
- Channel managers
- Guard managers
- Cables
- all the channels needed by the role, as input
channels - all the actions needed by the role, as true ?
skip - Morphisms
33Elements of the decomposition
- Glue
- Channel managers
- Guard managers
- Cables
- Morphisms
- maps the actions and channels of the cables to
the corresponding ones in the glue and in the
roles
34Properties of the decomposition
- Correctness
- the colimit of the decomposed program is equal to
the starting program - Possible generalization
- a diagram can be decomposed by decomposing each
role - morphisms entering a program become morphisms
entering the glue
35Roadmap
- Goal
- Background CommUnity
- Background tile logic
- Standard decomposition for CommUnity
- From CommUnity to tiles
- Conclusion and future work
36What we need
- We have to define a tile logic from a CommUnity
program - We need to define
- objects
- configurations
- observations
- tiles
- to specify the behavior
37Objects
- channels
- with a type and a modality (input/output)
- special boolean objects
- for the evaluation of guards
- synchronization objects
- representing actions
38Structure of a configuration
State
Role or glue
Channel fusion
Action synchro nization
Role or glue
Role or glue
Anchored configuration
39Structure of a configuration
State
Role or glue
Channel fusion
Action synchro nization
Role or glue
Role or glue
Unanchored configuration
40How to build a configuration
- We translate roles and glues
- We build the system using the parallel
composition through one cable operation - this allows to build the whole system thanks to
the property of the decomposition - we fix an order on cables for translating them
- the operation adds the channel fusion and action
synchronization parts - Eventually we add the state
41Constructors for roles and state
42Channel connectors
b
i
o
b
o
b
i
43Action synchronization connectors
1
44Translating the glue
i
i
i
1
i
i
45Parallel composition through one cable
- Channel part channels in the image of the same
channel of the cable are merged using channel
connectors - Action part we have to synchronize in all the
possible ways the actions of the two groups
mapped to each action of the cable
46Synchronizing actions
47Observations
- For the action part
- tick (action performed) or
- untick (action forbidden)
- For the channel part terms assigning
- to each output variable its data term
- to each special boolean object a predicate
- to each input variable a term, standing for a
guess on the actual value
a
r
48Tiles
- Specify the semantics of each part of the
configuration - Tiles for
- state
- channel connectors
- channel managers
- guard managers
- action synchronization connectors
49Tiles
- Specify the semantics of each part of the
configuration - Tiles for
- state
- update the values with the assignments and check
the validity of predicates - channel connectors
- channel managers
- guard managers
- action synchronization connectors
50Tiles
- Specify the semantics of each part of the
configuration - Tiles for
- state
- channel connectors
- apply consistent substitutions to data terms
- channel managers
- guard managers
- action synchronization connectors
51Tiles
- Specify the semantics of each part of the
configuration - Tiles for
- state
- channel connectors
- channel managers
- produce the assignments to the left and a tick on
the performed action to the right - guard managers
- action synchronization connectors
52Tiles
- Specify the semantics of each part of the
configuration - Tiles for
- state
- channel connectors
- channel managers
- guard managers
- produce the predicate to the left and a tick to
the right - action synchronization connectors
53Tiles
- Specify the semantics of each part of the
configuration - Tiles for
- state
- channel connectors
- channel managers
- guard managers
- action synchronization connectors
- select the allowed combinations of tick and
untick in the interfaces
54Tiles for mutual exclusion
55Tile for channel fusion
i
i
b
b
b
o
o
y1x2gt3 and x3lt4 and x1 y2x21
y1x2lt4 and x1
y1x2gt3 and x1 y2x21
2
1
1
2
2
3
1
56Tile for channel manager
i
cm ltx2x2x1, x2x2-x1gt
o
b
x2x2x1 x3true
a
r
i
cm ltx2x2x1, x2x2-x1gt
o
b
57Notation
- dia CommUnity diagram
- DS(dia) standard decomposition of dia
- TS(dia,) tile configuration for dia where
cables have been translated in the order
specified by , without state - TS(dia,,val) as before, but with state with
values val
58Properties of the encoding I
- TS(dia,,val) initial configuration of a tile ? ?
val. TS(dia,,val) is the final configuration - Such a tile (with empty observation) exists iff
there exists a computation of colim(dia) with
starting state val and final state val
59Properties of the encoding II
- To deal with tiles without state we need a
permutation ? to rearrange the interface - Bisimilarity results
- TS(dia,,val) TS(dia,,val) for each ,
- TS(dia,) ?TS(dia,) for each ,
- TS(dia,,val) TS(colim(dia),,val)
- TS(dia,) ?TS(colim(dia),,val)
60Roadmap
- Goal
- Background CommUnity
- Background tile logic
- Standard decomposition for CommUnity
- From CommUnity to tiles
- Conclusion and future work
61Algebraic vs categorical
- Algebraic Categorical
- Basic constructors Objects
- Aux. constructors Morphisms
- Representative Colimit
- up to equivalence
- Operat. semantics ?
- ? Architectural aspects
-
62Future work
- Further analyze the correspondence
- axiomatize connectors to have a correspondence
between normal form and colimit - Deal with other aspects of CommUnity
- localities
- mobility
- dynamic reconfiguration
- Mutual transfer of concepts and techniques
between the two approaches - Apply the approach to other formalisms
63Thanks
Questions?