self-adaptive systems : an introduction
TRANSCRIPT
Sagar Sen Scientist, Ecole des Mines, Nantes, France
Self-adaptive SoftwareAn Introduction
From?
Ecole des Mines, Nantes
City of Nantes(Rivers: Erdre, Loire|Population: 300,000)
Three real stories...
The Gardner Heist in Boston
1. In 1990, two men dressed as police officers broke into the Isabella Stewart Gardner Museum in Boston
2. Stole a Vermeer, five Degas and three Rembrandts.
3. Estimated cost : $500 million only /-!
4. OBSERVATION: Total failure of motion sensor and video surveillance systems!
An Analysis...
1. Video surveillance software system did not capture clear images in the darkness of the night!
2. Security guard was gagged and tied up! Software requires human interaction!
3. No automatic communication to police! The thieves had all night to displace the art! Software did not adapt to the situation that the guard was in distress!
4. Reward $5 million!
Software
The Ariane V501 Disaster• 4 juin, 1996, H0 at 08h35mn
• The Ariane 501 launcher tilts brutally and is subject to extreme aerodynamic forces.
• Self-destruct at H0+40sec.
• Cost: 500 million dollars!
Qu'est-il arrivé?
15 14 0
0Value (15)Sign (1)
63 62 52 51 0
0Mantissa (52)Exp (11)Sign (1)
CAST
For example,32769.445 leads to overflow in signed Int
Overflow in BOTH (main+redundant) Inertial Reference Systems
The Earthquake in Japan
• March 2011, Tohoku Earthquake close to Japan, Cost $235 billion
• Number of crisis management services were engaged in parallel
• Communication software helps engage ambulances, fire-fighters, medics, police...
Lessons learned...
Software is fragile! (Ariane!)
Software must adapt to context (Gardner Heist)
Software communicates with unreliable distributed services
Towards a Solution...Self-adaptive Software
Software should adapt at runtime
Architectural Elements in Self-adaptive Software
Services/Components
Software Function as a Service
Lifecyle of an OSGi service
Biological Analogy
Interacting cells in the body with specific function
The Notion of a Dynamic Service/Module
1. A software module or service that can be unloaded/loaded at runtime. (Open heart surgery)
2. Each module has its own life-cycle, memory space
3. Modules have well-defined interfaces and communicate using messages
4. Stopping/replacing a module need not stop the software system!
5. Available inherently in dynamic languages such as Python
6. Implemented in statically typed languages such as JAVA under the name Open Service Gateway Interface (OSGi)
Service Registry
Service Registry
Provider
subscribespublishes
msg
delivers
msg
Consumer
Service RegistryBiological Analogy
Gene Expressionvs.
Subscribing to and Using a ServiceService Registry vs. DNA
Context Manager
Context Manager
[NightFall, IntrusionDetected, Low Memory]Context Configuration
Context Manager
Sensors Monitoring Metrics(self)
Context Manager
Biological Analogy
Night Fall!
Adaptation Planner
Adaptation Planner Set of Rules
[Infrared Camera, Face Detection, GarbageCollector]System Configuration
[NightFall, IntrusionDetected, Low Memory]Context Configuration
Adaptation Planner
Biological Analogy
External/Internal Stimulus
Action decision
Component/Service Executor
Component Executor
[Infrared Camera, Face Detection, GarbageCollector]System Configuration
1subscribe
2
service3
4execute
Component ExecutorBiological Analogy
Taking Action!
Tekio: A Self-adaptive Vision System
With Santiago Hurtado, Colombia
Tekio: A Self-adaptive Vision System
Variability inTekio
Example Execution
Intrusion Detection Face Detection
Simple Demo
Is Tekio good enough?
Experimental Questions
Q1: Is Self-adaptation in Tekio fast?
Q2: Is Self-adaptation in Tekio robust?
Experimental Setup
Measurements1. Throughput in Frames per second (FPS)2. Memory usage in %3. CPU usage in %4. Settling time in seconds (time required to execute normally after adaptation)Machine: iMac with the Intel Core i3 Processor of 3.06GHz and 4GB 1333 MHz DDR3.
Comparison of Tekio to Static Implementation
Stress Testing
Lessons Learned?
Lessons Learned1. Modern software must adapt to context. Eg. Gmail docs on context such as desktop, mobile phone, geography, language, local ads.
2. Building a self-adaptive system relies of services that can be loaded dynamically.
3. The adaptation planner is a key component that maps context to a system configuration based on rules.
4. Self-adaptive systems need to be performant compared to traditional software. As seen in Tekio.
Thank you.