adaptation in distributed collective systems
Post on 22-Jul-2015
98 Views
Preview:
TRANSCRIPT
Distributed Adap.ve Systems (DAS) Unit
Adaptation in Distributed Collective Systems
Annapaola Marconi and Antonio Bucchiarone
Fondazione Bruno Kessler, Trento – Italy marconi@Ck.eu, bucchiarone@Ck.eu
12 March 2015, Milan
hGp://das.Ck.eu
@DAS_Unit
March, 12 2015 Adaptation in Distributed Collective Systems 2
Outline
§ Introduction
§ A Framework for Distributed Collective Systems o Application Model
o Adaptation mechanisms and strategies
o Incrementality, reduction, reuse
o Adaptation as AI planning problem
o Collective adaptation
§ Demonstrator and Evaluation
§ Conclusions
March, 12 2015 Adaptation in Distributed Collective Systems 3
§ Consist of diverse distributed heterogeneous entities o e.g., IT systems, devices, sensors, robots, people
§ Entities are autonomous but need to collaborate to accomplish collective tasks o each entity has its own objectives and requirements o expose functionalities to the outside world to enable collaboration
§ Environment in which they operate is highly dynamic: o changes of the context in which entities live; o entities dynamically change their behavior (including offered
functionalities) and join/leave the system; o changes in system requirements and preferences.
Distributed Collective Systems
DCS need to be ADAPTABLE BY DESIGN DCS need to be ADAPTED ON-THE-FLY
March, 12 2015 Adaptation in Distributed Collective Systems 4
Bremen Harbor § 4 km2, 120.000 storage places
§ 2 Million vehicles per year § 18 vehicle brands § 12 technical treatment stations
Aim: Develop a Car Logistic System supporting the management and operation of the port: § covering the whole car delivery process, from
delivery to disposition; § supporting the co-operation of the numerous
actors (i.e., cars, ships, trucks, storages, treatment areas, etc.) respecting their own procedures and business policies.
Car Logistic Scenario: Bremen Harbor
March, 12 2015 Adaptation in Distributed Collective Systems 5
Bremen Harbor § 4 km2, 120.000 storage places
§ 6 Million vehicles per year § 18 vehicle brands § 12 technical treatment stations
Aim: Develop a Car Logistic System supporting the management and operation of the port: § covering the whole car delivery process, from
delivery to disposition; § supporting the co-operation of the numerous
actors (i.e., cars, ships, trucks, treatment areas, etc.) respecting their own procedures and business policies.
Car Logistic Scenario: Bremen Harbor
Challenges: • Customizable procedures for each car (e.g., brand,
model, order) • Heterogeneity of actors/facilities involved (e.g., terminals,
storage areas, treatment stations, consignment areas, ships, trucks)
• System Dynamicity (e.g., actors/facilities join/leave the system, changes in procedures of system facilities, changes in regulations and norms)
• Context Dynamicity (e.g., unavailability or malfunctioning of the different port facilities, accidental damages of cars and trucks, human errors)
Fully exploit the benefits of the service-oriented paradigm and advance AI planning techniques to develop a context-aware distributed adaptive system.
March, 12 2015 Adaptation in Distributed Collective Systems 6
A Framework for Adaptive Context-aware SBS
En.ty
Provided Fragments
Business Process
En.ty
Provided Fragments
Business Process
En.ty
Provided Fragments
Business Process
En.ty
Provided Fragments
Business Process
Business processes: • Partial process specifications that allow
dynamic refinement and adaptation according to available system functionalities
• Modeled via Adaptive Pervasive Flow Language (APFL) an extension of traditional workflow language (BPEL) with abstract activities + preconditions/effects
Process Fragments: • Offered functionalities that can be
dynamically discovered/used by other entities
• Modeled as business processes Context Model: • Important characteristics of the
environment and of the entities that operate in it
• Used to define context preconditions/effects on process activities and goals on abstract activities
March, 12 2015 Adaptation in Distributed Collective Systems 7
Context Model
§ Shared representation of the system operation environment used to express goals, preconditions and effects on fragments
§ Defined through a set of context properties, each capturing a particular aspect of the system and its evolution (modeled as state transition systems) o Context properties evolve as an effect of fragment activity execution (normal
behavior) or as a result of exogenous changes (improbable behavior)
§ Context configuration: snapshot of the context at a specific time
March, 12 2015 Adaptation in Distributed Collective Systems 8
Business Processes and Fragments
§ Adaptable Pervasive Flow Language (APFL) o Extension of traditional workflow language o Standard constructs: sync/async WS communication, data manipulation,
complex control flow constructs o + Preconditions on activities
• Constrain the activity execution to specific context configurations • Used to catch violations and trigger adaptation
o + Effects on activities • Model the expected impact of activity execution on the context • Used to perform automatic reasoning on activities execution
o + Compensation goals on activities • Model the context configuration that has to be reached in case a (successfully
executed) activity needs to be compensated • Used to (partially/completely) roll-back a process instance
o + Abstract activities annotated with goals • Defined at design-time in terms of the goal (context configurations) it needs to achieve • Refined at run-time into an executable process wrt the available fragments, the current
context configuration and the goal to be achieved
March, 12 2015 Adaptation in Distributed Collective Systems 9
Business Processes and Fragments
Land Request
Check Gate Avail +
Gate1 Booked
Prepare Gate1
Gate2 Booked
Prepare Gate2
Departure Request Departure Departure
Reply
Business Process
Process Fragments
LANDING MANAGER
Land Request *
Gate1 Booked
Gate2 Booked
Departure Request
Departure Reply
P: ship_loc = harbor & ship_status = registered
P
P, E
P: gate1_status = ready E: gate1_status = assigned
SHIP
Land
Leave
GATE1
Prepare Land S
Prepare Land L
Land Guidance
Prepare Dep S
Precondition/Effects used for - detecting run-time violations - automatic reasoning for adaptation
Landing Departure
March, 12 2015 Adaptation in Distributed Collective Systems 10
Business Processes and Fragments
Land Request
Check Gate Avail +
Gate1 Booked
Prepare Gate1
Gate2 Booked
Prepare Gate2
Departure Request Departure Departure
Reply
Business Process
Provided Services
LANDING MANAGER
GATE1
Prepare Land S
Prepare Land L
Land Guidance
Prepare Dep S
Land Request *
Gate1 Booked
Gate2 Booked
Departure Request
Departure Reply
SHIP
Land
Leave
P
P, E
G
Goals used for - run-time context-aware service
composition
G: gate1_status = ready
Precondition/Effects used for - detecting run-time violations - automatic reasoning for adaptation
March, 12 2015 Adaptation in Distributed Collective Systems 11
Adaptation Mechanisms and Strategies
§ Adaptation needs o Need for refining an abstract activity within a process instance o Violation of a precondition of an activity that is going to be executed
§ Adaptation mechanisms o Refinement: dynamic refinement of abstract activity by context-aware
composition of available fragments o Local adaptation: identify a fragment composition that allows to re-start a
faulted process from a specific activity o Compensation: dynamically compute a compensation process for a specific
activity
March, 12 2015 Adaptation in Distributed Collective Systems 12
Adaptation Mechanisms and Strategies G3: CarProgressStoring = yes
March, 12 2015 Adaptation in Distributed Collective Systems 13
Adaptation Mechanisms and Strategies G3: CarProgressStoring = yes
P1: CarStatus = ok and CarRegistra.on = no
A1: CarStatus = nok
March, 12 2015 Adaptation in Distributed Collective Systems 14
Adaptation Mechanisms and Strategies
§ Adaptation needs o Need for refining an abstract activity within a process instance o Violation of a precondition of an activity that is going to be executed
§ Adaptation mechanisms o Refinement: dynamic refinement of abstract activity by context-aware
composition of available fragments o Local adaptation: identify a fragment composition that allows to re-start a
faulted process from a specific activity o Compensation: dynamically compute a compensation process for a specific
activity
§ Adaptation strategies o Combine adaptation mechanisms to solve complex adaptation problems
• E.g., Re-refinement, Backward adaptation
o Search for alternative solutions • E.g., Local on current activity -> Backward on current refinement -> Re-refinement -> …
o One-shot vs incremental adaptation
March, 12 2015 Adaptation in Distributed Collective Systems 15
§ Is it feasible to resolve at run time a large amount of complex adaptation problems? o No, in general it is not.
§ Solution: o interleaving of adaptation and execution o reduction of the complexity of adaptation problems o reuse of already solved adaptation solutions.
Incrementality, reduction, reuse
March, 12 2015 Adaptation in Distributed Collective Systems 16
ADAPTATION SOLUTION Process Fragment
ADAPTATION SOLUTION Process Fragment
PROBLEM REDUCTION
Relevant Process
Fragments
Relevant Context
ProperLes
ADAPTATION as AI PLANNING
ASTRO CAptEvo
Context-‐aware fragment composiLon
ADAPTED PROCESS Process
ADAPTATION NEED System ConfiguraLon,
Adapt. Trigger EnLty Instance
EXECUTION
Running System ConfiguraLon
? Process
Context
EnLty Instance
REDUCED ADAPTATION PROBLEM (Reduced) System Config.,
Goal, EnLty instance
INCREMENTAL ADAPTATION
m1 m2 m3 ; m1 m4 ; m3
AdaptaLon Strategy Adapted Process
SOLUTION REUSE
AdaptaLon knowledge base …
…
Problem SoluLon
<S3 , G3 , δ3 >
<S2 , G2 , δ2 >
<S1 , G1 , δ1 >
REDUCED ADAPTATION PROBLEM (Reduced) System Config.,
Goal, EnLty instance
ADAPTATION PROBLEM System ConfiguraLon, Goal, EnLty instance
Incrementality, reduction, reuse
§ INCREMENTALITY: incrementally addressing complex adaptation problems by interleaving problem solving and solution execution
§ REDUCTION: reduce complexity of each adaptation problem minimizing the search space according to the specific execution context
§ REUSE: reuse adaptation solutions by learning from past executions
March, 12 2015 Adaptation in Distributed Collective Systems 17
Adaptation as AI Planning Problem
Adaptation Goal
PLAN
NER
Adaptation Process
G
Σ ||
Madapt
STS2AP
FL
Σ C
Planning domain
Synthesized plan
Process Fragments
. . .
P1
Pn APFL2STS Σ P1
Σ Pn
. . .
State Transition Systems
GOAL
BUILDE
R
Planning Goal
G Σ
Context Configuration
. . .
C1
Cm CM2STS Σ C1
Σ Cm
. . . Madapt composition of fragments that, if executed from the current configuration
and in the absence of exogenous events, ensures that the resulting context configuration satisfies G.
March, 12 2015 Adaptation in Distributed Collective Systems 18
Adaptation as AI Planning Problem
PLAN
NER
Adaptation Process Σ ||
Madapt
STS2AP
FL
Σ C
Planning domain
Synthesized plan
APFL2STS, CM2STS Transformation of fragments and context configuration in STSs and removal of improbable events
GOAL BUILDER Translation of the adaptation goal in EAGLE planning goal
Adaptation Goal
G
GOAL
BUILDE
R
Planning Goal
G Σ
Process Fragments
. . .
P1
Pn APFL2STS Σ P1
Σ Pn
. . .
State Transition Systems
Context Configuration
. . .
C1
Cm CM2STS Σ C1
Σ Cm
. . .
March, 12 2015 Adaptation in Distributed Collective Systems 19
Adaptation as AI Planning Problem
PLAN
NER
Adaptation Process
Madapt
STS2AP
FL
Σ C Synthesized
plan
Product of fragment and context STSs synchronized on preconditions and effects
Adaptation Goal
G
GOAL
BUILDE
R
Planning Goal
G Σ
Process Fragments
. . .
P1
Pn APFL2STS Σ P1
Σ Pn State Transition
Systems
Context Configuration
. . .
C1
Cm CM2STS Σ
Σ
. . .
C1
Cm
. . . Σ ||
Planning domain
Σ ||
March, 12 2015 Adaptation in Distributed Collective Systems 20
Adaptation as AI Planning Problem
Adaptation Process
Madapt
STS2AP
FL
PLANNER sophisticated AI planning techniques for WS composition developed within the ASTRO project (non-determinism, extended goals) (2002 – Today)
Adaptation Goal
G
GOAL
BUILDE
R
Planning Goal
G Σ
Process Fragments
. . .
P1
Pn APFL2STS Σ P1
Σ Pn State Transition
Systems
Context Configuration
. . .
C1
Cm CM2STS Σ
Σ
. . .
C1
Cm
. . . PL
AN
NER
Σ C
Planning domain
Σ ||
Synthesized plan
March, 12 2015 Adaptation in Distributed Collective Systems 21
Adaptation as AI Planning Problem
STS2APFL Translation of the synthesized plan into an APFL executable adaptation process
Adaptation Goal
G
GOAL
BUILDE
R
Planning Goal
G Σ
Process Fragments
. . .
P1
Pn APFL2STS Σ P1
Σ Pn State Transition
Systems
Context Configuration
. . .
C1
Cm CM2STS Σ
Σ
. . .
C1
Cm
. . . PL
AN
NER
Σ C
Planning domain
Σ ||
Synthesized plan
Adaptation Process
Madapt
STS2AP
FL
March, 12 2015 Adaptation in Distributed Collective Systems 22
Implementation and Evaluation
§ We implemented the framework and evaluated on the CLS scenario
§ Demonstrator ASTRO-CAptEvo: o simulate the CLS scenario, view the
adaptation/composition mechanisms in action, inspect the internal system operation
Demo: hGp://www.astroproject.org/downloads/captevoDemo
Video: hGp://www.astroproject.org/downloads/captevoVideo.zip
IEEE ICWS/Services 2012: Best Paper Award & ServicesCup winner
March, 12 2015 Adaptation in Distributed Collective Systems 23
§ MODELING EFFORT AND COMPLEXITY § 29 entity types and process models, 69 fragment models, 40 context properties § Refinement:
§ Modularization and re-use of different specification elements (Context Properties and Fragments)
§ Each fragment can be adjusted by its provider separately from other fragments of the application
§ Entities/fragments can join/leave the system without affecting the implementation
§ Adaptation: § N. different adaptation cases to define considering only car damages and
stores unavailability (>170) § Adaptation processes correct by construction
Implementation and Evaluation
March, 12 2015 Adaptation in Distributed Collective Systems 24
Implementation and Evaluation
96% of problems solved in less than 30 seconds
96% of problems solved in less than 1 seconds
REDUCTION
REDUCTION + REUSE
March, 12 2015 Adaptation in Distributed Collective Systems 25
Implementation and Evaluation
New adaptaLon problems versus total number of adaptaLon needs (8 simulaLons)
March, 12 2015 Adaptation in Distributed Collective Systems 26
§ So far we have considered SELFISH ADAPTATION: “an entity adapts considering only its own objectives”
§ BUT o an adaptation might be “good” for one entity but not
for other entities in the same system o an adaptation in an entity might trigger other
adaptations in different parts of the system (chains of adaptations)
Selfish vs Collective adaptation
March, 12 2015 Adaptation in Distributed Collective Systems 27
Collective Adaptive Systems - Concepts
EnLty § Represents a physical or virtual
organiza.onal unit. § Comprises of a set of goals [1] and cells
[2]. § Associated with preferences, u.lity
func.ons and context. Cell § Described as a process consis.ng of
abstract and concrete ac.vi.es. § Specialized by replacing abstract
ac.vi.es with abstract or concrete ac.vi.es.
Cell A B C
Goal 1
Cell
D B G
Goal 2 En.ty
I J H
E
F
OR
Specializa.on of abstract ac.vity G
[1] Antonio Bucchiarone, Claudio Antares Mezzina, Heorhi Raik. A Goal Model for Collec>ve Adap>ve Systems. In FoCAS@SASO 2014, London, UK. [2] V. Andrikopoulos, A. Bucchiarone, S. Saez, D. Karastoyanova C. Mezzina: Towards Modeling and Execu>on of Collec>ve Adap>ve Systems. ICSOC Workshops 2013: 69-‐81
March, 12 2015 Adaptation in Distributed Collective Systems 28
Collective Adaptive Systems - Concepts
Ensemble § Associated with a goal. § Composi.on of specialized cells
w.r.t. goal and context. § Cells collaborate to achieve
ensemble goal. Cell
D E
Cell
D B
C
Cell
E F G
Ensemble
Goal
“Emergent aggrega>on of autonomous and self-‐adap>ve process-‐based elements”
March, 12 2015 Adaptation in Distributed Collective Systems 29
From Selfishness to Collective Goodness
§ Each CAS par.cipant cannot adapt its behavior in complete isola.on
§ Each adapta.on may nega.vely affect the goals of other par.cipants (i.e., conflicLng goals)
§ Each adapta.on can compromise the whole collabora.on
1. Every adapta>on must be resolved at the scale of the whole Ensemble.
2. Adapta>ons may need to be simultaneously applied to the behavior of mul>ple par>cipants
3. Adapta>ons must respect the specific condi>ons that par>cipa>on to the Ensemble imposes.
March, 12 2015 Adaptation in Distributed Collective Systems 30
Mul.-‐Modal Urban Mobility
Passenger
Des.na.ons Reach des.na.on
City council Minimize CO2/ Avoid traffic jams
FlexiBus FlexiBus Company
Manage buses & routes Follow assigned route
Taxi Transport passenger(s)
to des.na.on Car
March, 12 2015 Adaptation in Distributed Collective Systems 37
FlexiBus
ACCEPT DECLINE
Splite Fare with John and Mary?
March, 12 2015 Adaptation in Distributed Collective Systems 38
FlexiBus
ACCEPT DECLINE
REPLAN YOUR ROUTE?
March, 12 2015 Adaptation in Distributed Collective Systems 39
FlexiBus
Which part of the an Ensemble should be engaged to solve an adaptaLon need?
When an adaptaLon need will trigger collecLve AdaptaLon?
How we guarantee that an adaptaLon does not compromise the whole collaboraLon?
Distributed AdaptaLon approach for CAS
March, 12 2015 Adaptation in Distributed Collective Systems 41
Issue Resolution init
depend_found
cancelled
find solu.on
sol_found sol_not_found
returned
commiGed
no_dependency
targeted
sent
received
report 0 fitness
report consolidated fitness
communica.on
FlexiBus
An issue resolu.on is triggered when: • a problem is detected internally to a role; • a solver of a role received a request;
RM
March, 12 2015 Adaptation in Distributed Collective Systems 42
Issue Communication
init
sent
received
cancelled
commiGed
send issue to the target
receive reply from the target: all targets are received
commit solu.on to the target
cancel solu.on for this target
RM
PassDelay4
Bus
PassDelay
delay1
com1
FlexiBus
March, 12 2015 Adaptation in Distributed Collective Systems 43
Distributed Adaptation Tree
AND ………..
… … …
role instance boundaries
role instance boundaries
OR Internal Resolu.on
Consolida.on of all values from all communica.ons and calcula.on of the
overall resolu.on value.
RM FlexiBus
Decision among values received by two resolu.ons (Cell U.lity (i.e., Passenger))
Values: how well the corresponding target can
resolve the issue
March, 12 2015 Adaptation in Distributed Collective Systems 44
Multiple Ensembles Involvement
res1
res2 res3
com1
com2 com3 com4
res4 res5 res6 res7 res8
OR
AND
OR OR
Internal ResoluLon
Traffic Jam
Route1 Ensemble
Route2 Ensemble
Route3 Ensemble
FlexiBus
RM 1
RM 2 RM 3
March, 12 2015 Adaptation in Distributed Collective Systems 45
§ A framework for adaptation of distributed collective systems: o Dynamic
• Entities can leave/join the system at run-time • Fragment/process models can change at run-time
o Adaptive • Allows for partial specification of processes (abstract activities) and to leave the
handling of improbable/extraordinary situations to run-time (activity preconditions) • Provides different adaptation mechanisms properly coordinated through strategies
o Context-aware • Shared context model describing the system operational environment • Can be used to model exogenous events which may affect the system operation
o Collective (on-going) • Multiple entities must adapt simultaneously to properly addresses a critical runtime
condition and to preserve their collaboration and benefits. • Decentralized adaptation with distributed
o User-centric (on-going) • Smart Mobility scenario within the STREETLIFE project
Conclusions
March, 12 2015 Adaptation in Distributed Collective Systems 46
Conclusions
CAR LOGISTIC INTEGRATED MOBILITY
CHILDREN MOBILITY DRONES FLEET
March, 12 2015 Adaptation in Distributed Collective Systems 47
A. Bucchiarone, C. Mezzina, M. Pistore, H. Raik, G. ValeGo: CollecLve AdaptaLon in Process-‐Based Systems. SASO 2014: 151-‐156. A. Bucchiarone, C. Antares Mezzina, H. Raik. A Goal Model for CollecLve AdapLve Systems. In FoCAS@SASO 2014, London, UK.
V. Andrikopoulos, A. Bucchiarone, S. Saez, D. Karastoyanova C. Mezzina: Towards Modeling and ExecuLon of CollecLve AdapLve Systems. ICSOC Workshops 2013: 69-‐81 A. Bucchiarone, A. Marconi, C. Antares Mezzina, M. Pistore, H. Raik. On-‐the-‐Fly AdaptaLon of Dynamic Service-‐Based Systems: Incrementality, ReducLon and Reuse. ICSOC 2013, Berlin, Germany, December 2-‐5, 2013:146-‐161. H. Raik, A. Bucchiarone, N. Khurshid, A. Marconi, and M. Pistore. Astro-‐captevo: Dynamic context-‐aware adapta>on for service-‐based systems. In SERVICES, pages 385–392, 2012. A. Bucchiarone, A. Marconi, M. Pistore, and H. Raik. Dynamic adapta>on of fragment-‐based and context-‐aware business processes. In ICWS, pages 33–41, 2012. Antonio Bucchiarone, Alberto Lluch-‐Lafuente, Annapaola Marconi, Marco Pistore: A Formalisa>on of Adaptable Pervasive Flows. WS-‐FM 2009: 61-‐75 Marco Pistore, Paolo Traverso: Planning as Model Checking for Extended Goals in Non-‐determinis>c Domains. IJCAI 2001: 479-‐486
References
March, 12 2015 Adaptation in Distributed Collective Systems 48
PhD Symposium @ SASO 2015
hgp://www.saso-‐conference.org/
March, 12 2015 Adaptation in Distributed Collective Systems 49
hgp://www.agentgroup.unimore.it/DAS2015/
top related