kaos: a klaim extension for reasoning on programmable qos · kaos: a klaim extension for reasoning...

49
KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto [email protected] Dipartimento di Informatica Universit ´ a di Pisa In cooperation with: R. De Nicola, G. Ferrari, U. Montanari and R. Pugliese KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.1/15

Upload: vuonghuong

Post on 01-Apr-2019

216 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: a KLAIM Extensionfor

Reasoning on Programmable QoSEmilio Tuosto

[email protected]

Dipartimento di Informatica

Universita di Pisa

In cooperation with:

R. De Nicola, G. Ferrari, U. Montanari and R. Pugliese

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.1/15

Page 2: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Plan of the talk

WAN Programming with QoS

A representation of QoS parameters

KAOS

KAOS & Hypergraphs: reasoning on QoS issues

Details in International Symposium on Verification - Theory andPractice (LNCS)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.2/15

Page 3: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Plan of the talk

WAN Programming with QoS

A representation of QoS parameters

KAOS

KAOS & Hypergraphs: reasoning on QoS issues

Details in International Symposium on Verification - Theory andPractice (LNCS)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.2/15

Page 4: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Plan of the talk

WAN Programming with QoS

A representation of QoS parameters

KAOS

KAOS & Hypergraphs: reasoning on QoS issues

Details in International Symposium on Verification - Theory andPractice (LNCS)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.2/15

Page 5: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Plan of the talk

WAN Programming with QoS

A representation of QoS parameters

KAOS

KAOS & Hypergraphs: reasoning on QoS issues

Details in International Symposium on Verification - Theory andPractice (LNCS)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.2/15

Page 6: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Plan of the talk

WAN Programming with QoS

A representation of QoS parameters

KAOS

KAOS & Hypergraphs: reasoning on QoS issues

Details in International Symposium on Verification - Theory andPractice (LNCS)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.2/15

Page 7: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Plan of the talk

WAN Programming with QoS

A representation of QoS parameters

KAOS

KAOS & Hypergraphs: reasoning on QoS issues

Details in International Symposium on Verification - Theory andPractice (LNCS)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.2/15

Page 8: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Wide Area Network Programming Issues

Absence of centralised control

Administrative domains

Interoperability

“Mobility” (of resources and computation)

Network Awareness

Applications are location dependent

Locations have different features

and allow multiple (security) policies

Independently programmed in a distributed environment

Service Level Agreement

Security

... KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.3/15

Page 9: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Klaim

Multiple TS

Localities: first class citizens

Process migration

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.4/15

Page 10: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Klaim

Multiple TS

Localities: first class citizens

Process migration

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.4/15

Page 11: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Klaim

Multiple TS

Localities: first class citizens

Process migration

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.4/15

Page 12: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Klaim

Multiple TS

Localities: first class citizens

Process migration

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.4/15

Page 13: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Klaim

Multiple TS

Localities: first class citizens

Process migration

site s’site s

a(t)@s’

eval(P’)@s’P’

R

P

Q Q’

R’

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.4/15

Page 14: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Klaim

Multiple TS

Localities: first class citizens

Process migration

site s’site s

eval(P’)@s’P’

R’

P

R

Q Q’

a(t)@s’

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.4/15

Page 15: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Klaim

Multiple TS

Localities: first class citizens

Process migration

site s’site s

eval(P’)@s’ R’

Q

R

Q’

a(t)@s’

P’P

P ::= nil

| α.P

| P1 | P2

α ::= a@s

a ::= ... // Klaim actions

| ε(P )

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.4/15

Page 16: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Gateways

Coordinators (super processes)

Dynamic creation of sites

Gateway connection management

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.5/15

Page 17: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Gateways

Coordinators (super processes)

Dynamic creation of sites

Gateway connection management

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.5/15

Page 18: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Gateways

Coordinators (super processes)

Dynamic creation of sites

Gateway connection management

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.5/15

Page 19: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Gateways

Coordinators (super processes)

Dynamic creation of sites

Gateway connection management

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.5/15

Page 20: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Gateways

Coordinators (super processes)

Dynamic creation of sites

Gateway connection management

Q’

R’

|P’

site s’site s

R

Q

P

|P

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.5/15

Page 21: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Gateways

Coordinators (super processes)

Dynamic creation of sites

Gateway connection management

site s’site s

R’

|P’

Q’

|P

Q

P

R

new(s’,|P’)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.5/15

Page 22: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Gateways

Coordinators (super processes)

Dynamic creation of sites

Gateway connection management

site s’site s

R’R

Q

|P

P

|P’

Q’

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.5/15

Page 23: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Gateways

Coordinators (super processes)

Dynamic creation of sites

Gateway connection management

κ

site s’site s

R’

Q’Q

P

R

P ::= γ.P | P1 | P2

γ ::= α

| ν(s · κ)

|κ_ s

| sκ^

| δ l

Cost κ abstracts characteristics of connections according to many

“dimensions” (bandwidth, latency, distance, access rights ...)KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.5/15

Page 24: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Connection costs

Algebra on costs: c-semiring. 〈A,+,×,0,1〉 is a constraint semiringif A is a set (0,1 ∈ A), and + and × are binary operations on A thatsatisfy the following properties:

+ is commutative, associative, idempotent, 0 is its unit elementand 1 is its absorbing element;

× is commutative, associative, distributes over +, 1 is its unitelement, and 0 is its absorbing element.

The additive operation of a c-semiring induces a partial order on A

defined as a ≤A b ⇐⇒ ∃c : a + c = b. The minimal element is thus 0

and the maximal 1

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.6/15

Page 25: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Examples of connection costs

〈N,min,+,+∞, 0〉 , the c-semiring of natural numbers N where

the additive operation is min

the multiplicative operation is the sum over natural numbers

〈℘({A}),∪,∩, A,A}〉 , c-semiring of capabilities A where

the additive operation is ∪

the multiplicative operation is ∩

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.7/15

Page 26: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Example

s

3. download message

2. check message

1. message on s

Send ’msg’ to t

t

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.8/15

Page 27: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Example

s

3. download message

2. check message

1. message on s

Send ’msg’ to t

t

x

y

zt

<10,{i,o},2>

<10,{i},20> <150,{i,o},2>

<100,{i,o,n},2>

<300,{i,o},60> s

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.8/15

Page 28: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Example

s

3. download message

2. check message

1. message on s

Send ’msg’ to t

t

x

y

zt

<10,{i,o},2>

<10,{i},20> <150,{i,o},2>

<100,{i,o,n},2>

<300,{i,o},60> s

Costs are triples κ = 〈d, C, p〉 where

1. d is the geographical distance (in Km);

2. C ⊆ {i, o, n} are the capabilities, where i, o and n stand forinput, output and creation of new nodes, respectively;

3. p is the price (in euros).

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.8/15

Page 29: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS: Example

Costs are elements of the cartesian product of

1. (N,min,+,+∞, 0),

2. (℘({i, o, n}), glb,∩, {i, o, n}, {i, o, n}),

3. (Q,min,+,+∞, 0).

proved to be a c-semiring [BMR97]Operations × and + are

〈d, C, p〉 × 〈d′, C ′, p′〉 = 〈d + d′, C ∩ C ′, p + p′〉

〈d, C, p〉 + 〈d′, C ′, p′〉 = 〈min{d, d′}, glb{C,C ′},min{p, p′}〉.

Accordingly, the neutral elements of × and +, respectively are de-

fined as 1 = 〈0, {i, o, n}, 0〉 and 0 = 〈+∞, ∅,+∞〉.

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.9/15

Page 30: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Hypergraphs Programming model2

Tackling new non-functional computational phenomena of systemsusing SHR.The metaphor is

“WAN systems as Hypergraphs”

“WAN computations as SHR”

In other words:

Components are represented by hyperedges

Systems are bunches of (connected) hyperedges

Computing means to rewrite hyperedge...

...according to a synchronisation policy

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.10/15

Page 31: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Hyperedges and Hypergraphs Syntax

A hyperedge generalises edges: It connects more than two nodes

L : 3, L(y, z, x), •y

•x L3

1

2 •z

G ::= nil∣

∣ ν y.G∣

∣ L(~x)∣

∣ G|G

Syntactic Judgement Γ ` G, fn(G) ⊆ Γ

An example:

L : 3, M : 2

x, y ` ν z.(L(y, z, x)|M(y, z))

•y

L

���� CC

CCC M

CCCC

•x ◦z

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.11/15

Page 32: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Hyperedges and Hypergraphs Syntax

A hyperedge generalises edges: It connects more than two nodes

L : 3, L(y, z, x), •y

•x L3

1

2 •z

G ::= nil∣

∣ ν y.G∣

∣ L(~x)∣

∣ G|G

Syntactic Judgement Γ ` G, fn(G) ⊆ Γ

An example:

L : 3, M : 2

x, y ` ν z.(L(y, z, x)|M(y, z))

•y

L

���� CC

CCC M

CCCC

•x ◦z

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.11/15

Page 33: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Hyperedges and Hypergraphs Syntax

A hyperedge generalises edges: It connects more than two nodes

L : 3, L(y, z, x), •y

•x L3

1

2 •z

G ::= nil∣

∣ ν y.G∣

∣ L(~x)∣

∣ G|G

Syntactic Judgement Γ ` G, fn(G) ⊆ Γ

An example:

L : 3, M : 2

x, y ` ν z.(L(y, z, x)|M(y, z))

•y

L

���� CC

CCC M

CCCC

•x ◦z

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.11/15

Page 34: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Hyperedges and Hypergraphs Syntax

A hyperedge generalises edges: It connects more than two nodes

L : 3, L(y, z, x), •y

•x L3

1

2 •z

G ::= nil∣

∣ ν y.G∣

∣ L(~x)∣

∣ G|G

Syntactic Judgement Γ ` G, fn(G) ⊆ Γ

An example:

L : 3, M : 2

x, y ` ν z.(L(y, z, x)|M(y, z))

•y

L

���� CC

CCC M

CCCC

•x ◦z

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.11/15

Page 35: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Hyperedges and Hypergraphs Syntax

A hyperedge generalises edges: It connects more than two nodes

L : 3, L(y, z, x), •y

•x L3

1

2 •z

G ::= nil∣

∣ ν y.G∣

∣ L(~x)∣

∣ G|G

Syntactic Judgement Γ ` G, fn(G) ⊆ Γ

An example:

L : 3, M : 2

x, y ` ν z.(L(y, z, x)|M(y, z))

•y

L

���� CC

CCC M

CCCC

•x ◦z

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.11/15

Page 36: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Replacement of Hyperedges

L → G

Benefits:

Powerful model of system composition (π, π-I, fusion)

LTS for Ambient ...

...and for Klaim

and path reservation for KAOS

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.12/15

Page 37: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Replacement of Hyperedges

L → G

� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �

� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �

G1

5

4

2

1 G

L

3

G2’

���

���

����

������

��� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �

G2

Benefits:

Powerful model of system composition (π, π-I, fusion)

LTS for Ambient ...

...and for Klaim

and path reservation for KAOS

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.12/15

Page 38: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Replacement of Hyperedges

L → G

� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �

� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �

G2’G1

G

L

5

4

2

1

3

����

���

���

����

����

Benefits:

Powerful model of system composition (π, π-I, fusion)

LTS for Ambient ...

...and for Klaim

and path reservation for KAOS

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.12/15

Page 39: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Replacement of Hyperedges

L → G

� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �

� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �

G2’G1

G

L

5

4

2

1

3

����

���

���

����

����

Edge replacement: local

Synchronisation as distributedconstraint solving

New node creation

Node fusion: mobility model

Benefits:

Powerful model of system composition (π, π-I, fusion)

LTS for Ambient ...

...and for Klaim

and path reservation for KAOS

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.12/15

Page 40: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Replacement of Hyperedges

L → G

� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �� � � � � �

� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �� � � � �

G2’G1

G

L

5

4

2

1

3

����

���

���

����

����

Edge replacement: local

Synchronisation as distributedconstraint solving

New node creation

Node fusion: mobility model

Benefits:

Powerful model of system composition (π, π-I, fusion)

LTS for Ambient ...

...and for Klaim

and path reservation for KAOS

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.12/15

Page 41: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS & Hypergraphs

[[ s ::L P ]] = Γ ` (ν ~x, p)([[ P ]]p |

� sm,n(~u, ~x, p) |

n∏

j=1

Gκj

tj(xj, vj))

ζ ζ

ζ

GG

.....

.....

.....

.....

.....

.....

G G

P

[[ nil ]]p = nil

[[ o〈t〉 ]]p = Lo〈t〉(p)

[[ γ.P ]]p = Lγ.P (p)

[[ ε(P )@s ]]p = (ν u)(εT (P )s (u, p) | SP (u))

[[ P1 | P2 ]]p = [[ P1 ]]p | [[ P2 ]]p

[[ rec X. P ]]p = [[ P [rec X. P /X ] ]]p.

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.13/15

Page 42: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS & Hypergraphs

[[ s ::L P ]] = Γ ` (ν ~x, p)([[ P ]]p |

� sm,n(~u, ~x, p) |

n∏

j=1

Gκj

tj(xj, vj))

ζ ζ

ζ

GG

.....

.....

.....

.....

.....

.....

G G

P

[[ nil ]]p = nil

[[ o〈t〉 ]]p = Lo〈t〉(p)

[[ γ.P ]]p = Lγ.P (p)

[[ ε(P )@s ]]p = (ν u)(εT (P )s (u, p) | SP (u))

[[ P1 | P2 ]]p = [[ P1 ]]p | [[ P2 ]]p

[[ rec X. P ]]p = [[ P [rec X. P /X ] ]]p.

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.13/15

Page 43: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

Graph for the message example

•x

Gκzxx

HHHH

Hoo

Gκtxx

ttttt

55kkkkkkkkkk?

� x

yyyy

y

OO

? ◦

◦ ◦ ◦ Gκxzz

##HHHH

H

� z

��

HHHHH

◦ Gκzss

// •s

� t

FFFF

F

wwwww// •t

Gκxt

t

wwwww

oo •z

Gκszz

oo ◦

� s

OO

? ◦ Gκty

y// •y

Gκyz

z

xxxx

x

;;wwwww

?

εTs

OO

?

� y

OO

◦ L〈“bigfile′′,file〉

OO

◦ SFf,too

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.14/15

Page 44: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS Graph semantics: pros & cons

– Many productions (recently reduced :-)

+ Determines the “optimal” path (also KAOS)

+ Path reservation

+ Path routing

Theorem KAOS remote actions are routed on paths with minimal cost(wrt the c-semiring operations)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.15/15

Page 45: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS Graph semantics: pros & cons

– Many productions (recently reduced :-)

+ Determines the “optimal” path (also KAOS)

+ Path reservation

+ Path routing

Theorem KAOS remote actions are routed on paths with minimal cost(wrt the c-semiring operations)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.15/15

Page 46: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS Graph semantics: pros & cons

– Many productions (recently reduced :-)

+ Determines the “optimal” path (also KAOS)

+ Path reservation

+ Path routing

Theorem KAOS remote actions are routed on paths with minimal cost(wrt the c-semiring operations)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.15/15

Page 47: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS Graph semantics: pros & cons

– Many productions (recently reduced :-)

+ Determines the “optimal” path (also KAOS)

+ Path reservation

+ Path routing

Theorem KAOS remote actions are routed on paths with minimal cost(wrt the c-semiring operations)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.15/15

Page 48: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS Graph semantics: pros & cons

– Many productions (recently reduced :-)

+ Determines the “optimal” path (also KAOS)

+ Path reservation

+ Path routing

Theorem KAOS remote actions are routed on paths with minimal cost(wrt the c-semiring operations)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.15/15

Page 49: KAOS: a KLAIM Extension for Reasoning on Programmable QoS · KAOS: a KLAIM Extension for Reasoning on Programmable QoS Emilio Tuosto etuosto@di.unipi.it Dipartimento di Informatica

KAOS Graph semantics: pros & cons

– Many productions (recently reduced :-)

+ Determines the “optimal” path (also KAOS)

+ Path reservation

+ Path routing

Theorem KAOS remote actions are routed on paths with minimal cost(wrt the c-semiring operations)

KAOS: a KLAIM ExtensionforReasoning on Programmable QoS – p.15/15