SlideShare a Scribd company logo
1 of 19
Download to read offline
Coen De Roover                      Christophe Scholliers
Software Languages Lab, Brussels      Wouter Amerijckx




The STADiUM language framework for
capturing domain-specific interaction patterns
Motivating Example
... SE problems associated with event-based programming
                                           Tent C
                                       Tent B
                                  Tent A




                             Component:
                                                                                         subscribed to single event
    Component:
  HumiditySensor
                          TemperatureSensor

                                                               Component:
                                                                                            receiveEvent(Event e) {
                                  online
                                                             HeatingController
                                                                                               // invoke application logic
         online
                           temperatureReading            online
                                                                                               // publish new event
    humidityReading

                                                            adjustHeating
                                                                                            }
                         Decentralized Event Bus
                                                                                            difficult to compose event handlers
                                                online

                                            humidityReading
                      adjustHeating
                                           temperatureReading                    subscribed to multiple events
                           Component:
                                                                                   dispatch over received events
                        ComfortLevelMonitor

                                                                                   manage state (event sequences)
                                                                                   relate events through matching
Motivating Example
... problems inherent to the STADiUM domain
                                           Tent C
                                       Tent B
                                  Tent A




                                                                                         compensate reactions to stale readings
                             Component:
                          TemperatureSensor
    Component:
  HumiditySensor
                                                               Component:
                                                                                            state changes
                                                             HeatingController

         online
                                  online
                                                                                            context-dependent behavioral adaptions
                           temperatureReading            online
    humidityReading

                                                            adjustHeating



                         Decentralized Event Bus


                                                online


                      adjustHeating
                                            humidityReading                      events carry sensor readings
                                           temperatureReading

                                                                                  readings expire
                           Component:
                        ComfortLevelMonitor
                                                                                  readings subsume others
                                                                                           application-specific: time, content, origin
CrimeSPOT in a Nutshell
... a domain-specific language for programming WSN interactions
                    minimize accidental complexity so developers can
                    focus on essential complexity


         m atch sub
                     sume    node-centric perspective
dispatch     expir
                   e
compensate                      specify interactions declaratively
            ement
state manag
                             network-centric perspective
                                specify which rules govern which components

                             configurable runtime
                                application-specific semantics of events
nod
The CrimeSPOT runtime                                             cen e-
... architectural overview
                                                                     tric

          CrimeSPOT runtime
                                           inference engine
            Inference Layer                  evaluates rules against facts
   Fact            Inference        Rule     tracks causality
   Base             Engine          Base



            Reification Layer               reification engine
      Reification          Configuration       reifies events as facts
       Engine                Base
                                             expiration and subsumption
           Infrastructure Layer

            Middleware Bridge
            Middleware Bridge              middleware bridge
                                             transfers events to and from bus
                                             bridge to LooCI
nod
Distributed Interaction Rules                                   cen e-
... publishing facts on the network                                tric


fact in fact base
    temperatureReading(Celsius=27)@[factExpires(Seconds=600)]



matching condition in rule
    celsiusReading(Celsius=?value)@[to(Mac=*)]
     ← temperatureReading(Celsius=?value)
nod
Distributed Interaction Rules                                     cen e-
... invoking application logic                                       tric

              from body of rule

 e.g., unicast a reading upon a request
      humidityReading(Percent=?p)@[to(MAC=?mac, ID=?id)]
       ← requestForHumidity()@[from(MAC=?mac, ID=?id)],
         ?p is this.getHumidity()


 e.g., broadcast a reading at set intervals
      humidityReading(Percent=?p)@[to(MAC=*),factExpires(Seconds=600)]
       ← ?p is this.getHumidity()@[renewEvery(Seconds = 600)]
nod
Distributed Interaction Rules                                              cen e-
... invoking application logic                                                tric

               in head of rule

 e.g., a state change that has to be undone
     this.adjustHeater
      ← adjustHeating(Level=?h)

     class HeatingController
       private CSAction adjustHeater = new CSAction() {
          public void activated(CSVariableBindings bindings) { //adjust heating }
          public void deactivate(CSVariableBindings bindings) { //reset heating }
       };
     }
nod
Reifying Events as Facts                                                            cen e-
... fine-tuning the reification engine                                                 tric

              mapping LooCI events to CrimeSPOT facts
                                                          Configuration
                                                             Base
                Decentralized
                 Event Bus



                                         Middleware           Reification              Fact
                                Event                                       Fact
                                           Bridge              Engine                 Base



                                     Event            Drop?          Subsumes?     Assert
                                   Reification




e.g., temperature readings
      mapping temperatureReading(Celsius=?temp)@[factExpires(Seconds=600)]
            <=> Event_101(Integer=?temp).
nod
Reifying Events as Facts                                           cen e-
... fine-tuning the reification engine                                tric

              controlling fact subsumption


e.g., a humidity reading subsumes others from same tent
      incoming humidityReading(Percent=?new)@[from(ID=?id)]
      subsumes humidityReading(Percent=?old)@[from(ID=?otherid)]
      provided online(Tent=?tent)@[from(ID=?id)],
               online(Tent=?tent)@[from(ID=?otherid)]
net
WSN Application as a Whole                                            wo
                                                                  cen rk-
... which CrimeSPOT code goes where?
                                                                     tric
                 quantify over components
                 enumerate rules and supporting code

e.g., tent-related code shared by all components

 *{
   online(Tent=?tnt)@[to(MAC=*),factExpires(Seconds=3600)]
      ← ?tnt is this.getTentBasedOnGPSReading()@[renewEvery(Seconds=3600)].
 }
 *.java {
   private CSValue getTentBasedOnGPSReading() { return ... }
 }
net
WSN Application as a Whole                                             wo
                                                                   cen rk-
... reusing CrimeSPOT code
                                                                      tric

                macro definition and application

ComfortLevelMonitor {
  subsumesOlderFromSameTent(humidityReading,Percent).
  subsumesOlderFromSameTent(temperatureReading,Celsius).
}
       * { defmacro subsumesOlderFromSameTent($reading,$type):
              incoming $reading($type =?new)@[from(ID=?id)]
              subsumes $reading($type =?old)@[from(ID=?otherid)]
              provided online(Tent=?tent)@[from(ID=?id)],
                      online(Tent=?tent)@[from(ID=?otherid)]
       }
Motivating Example Revisited
... lines of CrimeSPOT code for the entire WSN Application




                                73
Motivating Example Revisited
... TemperatureSensor and HumiditySensor components
 1.   TemperatureSensor,	
  HumiditySensor,	
  HeatingController	
  {
 2.   	
  	
  	
  	
  publishPresenceEvery($onlineInterval).
 3.   }
          4.    TemperatureSensor	
  {
          5.    	
  	
  	
  	
  temperatureMapping($readingInterval).	
  	
  	
  	
  
          6.    	
  	
  	
  	
  temperatureReading(Celsius=?temp)@[to(MAC=*),
          7.    	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  factExpires($readingInterval)]	
  
          8.    	
  	
  	
  	
  	
  	
  <-­‐	
  ?temp	
  is	
  this.getTemperature()@[renewEvery($readingInterval)].
          9.    	
  }
          10.   	
  
          11.   	
  TemperatureSensor.java	
  {
          12.   	
  	
  	
  	
  private	
  CSValue	
  getTemperature()	
  {	
  return	
  ...	
  }
          13.   	
  }
                                               14. 	
  HumiditySensor	
  {
                                               15. 	
  	
  	
  	
  humidityMapping($readingInterval).
                                               16. 	
  	
  	
  	
  humidityReading(Percent=?p)@[to(MAC=*),
                                               17. 	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  factExpires($readingInterval)]
                                               18. 	
  	
  	
  	
  	
  <-­‐	
  ?p	
  is	
  this.getHumidity()@[renewEvery($readingInterval)]	
  
                                               19. 	
  }
                                               20. 	
  
                                               21. 	
  HumiditySensor.java	
  {
                                               22. 	
  	
  	
  	
  private	
  CSValue	
  getHumidity()	
  {	
  return	
  ...	
  }
                                               23. 	
  }
Motivating Example Revisited
... component HeatingController

24.   HeatingController	
  {
25.   	
  	
  	
  	
  incoming	
  adjustHeating(Level=?new)	
  subsumes	
  adjustHeating(Level=?old).
26.   	
   	
   	
   	
   	
   	
  
27.   	
  	
  	
  	
  this.adjustHeater
28.   	
  	
  	
  	
  	
  	
  <-­‐	
  adjustHeating(Level=?h).
29.   }
30.   	
  
31.   HeatingController.java	
  {
32.   	
  	
  private	
  CSAction	
  adjustHeater	
  =	
  new	
  CSAction()	
  {
33.   	
  	
  	
  	
  	
  public	
  void	
  activated(CSVariableBindings	
  bindings)	
  {	
  //adjust	
  heating	
  }
34.   	
  	
  	
  	
  	
  public	
  void	
  deactivate(CSVariableBindings	
  bindings)	
  {	
  //reset	
  heating	
  }
35.   	
  	
  };	
  	
  
36.   }
Motivating Example Revisited
... component ComfortLevelMonitor
37.	
  	
  ComfortLevelMonitor	
  {	
  
38.	
  	
  	
  	
  temperatureMapping($readingInterval).
39.	
  	
  	
  	
  humidityMapping($readingInterval).
40.	
  	
  	
  	
  subsumesOlderFromSameTent(humidityReading,Percent).
41.	
  	
  	
  	
  subsumesOlderFromSameTent(temperatureReading,Celsius).
42.	
  	
  	
  	
  incoming	
  online(Tent=?tnt,Component=?c)@[from(MAC=?m)]	
  
43.	
  	
  	
  	
  subsumes	
  online(Tent=?otnt,Component=?c)@[from(MAC=?m)].	
  	
                                                                                                    	
  
44.	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  
45.	
  	
  	
  	
  this.logComfortLevel
46.	
  	
  	
  	
  	
  	
  <-­‐	
  humidityReading(Percent=?h)@[from(MAC=?hm,ID=?hi)],	
  	
  	
  	
  	
  	
  	
  
47.	
  	
  	
  	
  	
  	
  	
  	
  	
  temperatureReading(Celsius=?t)@[from(MAC=?tm,ID=?ti)],
48.	
  	
  	
  	
  	
  	
  	
  	
  	
  online(Tent=?tnt)@[from(MAC=?hm,ID=?hi)],
49.	
  	
  	
  	
  	
  	
  	
  	
  	
  online(Tent=?tnt)@[from(MAC=?tm,ID=?ti)].
50.	
             	
   	
  	
  	
  	
  
37.	
  	
  	
  	
  adjustHeating(Level=?heatingLevel)@[to(MAC=?hcm,ID=?hci),
38.	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  factExpires($readingInterval)]
39.	
  	
  	
  	
  	
  	
  <-­‐	
  temperatureReading(Celsius=?t)@[from(MAC=?tm,ID=?ti)],
40.	
  	
  	
  	
  	
  	
  	
  	
  	
  online(Tent=?tnt)@[from(MAC=?tm,ID=?ti)],
41.	
  	
  	
  	
  	
  	
  	
  	
  	
  ?heatingLevel	
  is	
  this.computeHeatingLevel((Number)?t),
42.	
  	
  	
  	
  	
  	
  	
  	
  	
  online(Component=`HeatingController,Tent=?tnt)@[from(MAC=?hcm,ID=?hci)].	
  
43.	
  	
  }	
  
44.	
  
45.	
  	
  ComfortLevelMonitor.java	
  {
46. 	
  	
  	
  private	
  CSValue	
  computeHeatingLevel(Number	
  t)	
  {	
  return	
  ...	
  }
47. 	
  }
Motivating Example Revisited
... code shared by all components
48.   	
  *.java	
  {
49.   	
  	
  	
  	
  private	
  CSValue	
  getTentBasedOnGPSReading()	
  {	
  return	
  ...	
  }
50.   	
  }
51.   	
  
52.   	
  *	
  {	
  	
  	
  	
  
53.   	
  	
  	
  	
  defvar	
  $readingInterval:	
  Seconds=600.
54.   	
  	
  	
  	
  defvar	
  $onlineInterval:	
  Seconds=3600.
55.   	
  
56.   	
  	
  	
  	
  defmacro	
  temperatureMapping():
57.   	
  	
  	
  	
  	
  	
  	
  	
  mapping	
  temperatureReading(Celsius=?temp)@[factExpires($readingInterval)]	
  
58.   	
   	
  	
  	
  	
  	
  <=>	
  Event_101(Integer=?temp).
59.   	
   	
  	
  	
  	
  	
  	
  	
  	
  
60.   	
  	
  	
  	
  defmacro	
  humidityMapping():
61.   	
  	
  	
  	
  	
  	
  	
  	
  mapping	
  humidityReading(Percent=?h)@[factExpires($readingInterval)]	
  
62.   	
   	
  	
  	
  	
  	
  <=>	
  Event_102(Integer=?h).
63.   	
  
64.   	
  	
  	
  	
  defmacro	
  publishPresenceEvery($time):
65.   	
  	
  	
  	
  	
  	
  	
  online(Tent=?tnt,Component=`$COMPONENT_NAME)@[to(MAC=*),factExpires($time)]	
  	
  
66.   	
  	
  	
  	
  	
  	
  	
  	
  	
  	
  <-­‐	
  ?tnt	
  is	
  this.getTentBasedOnGPSReading()@[renewEvery($time)].
67.   	
   	
  	
  	
  	
  	
  	
  	
  	
  
68.   	
  	
  	
  	
  defmacro	
  subsumesOlderFromSameTent($reading,$type):
69.   	
  	
  	
  	
  	
  	
  	
  incoming	
  $reading($type=?new)@[from(MAC=?mac)]
70.   	
  	
  	
  	
  	
  	
  	
  subsumes	
  $reading($type=?old)@[from(MAC=?othermac)]
71.   	
  	
  	
  	
  	
  	
  	
  provided	
  online(Tent=?tnt)@[from(MAC=?mac)],
72.   	
   	
  	
  	
  	
  	
  	
  	
  online(Tent=?tnt)@[from(MAC=?othermac)].
73.   	
  }
Evaluation
... using CrimeSPOT on top of LooCI on SunSPOT motes
 73 lines of code for motivating example

                               LooCI: component deployment, wiring
                                      event routing, service discovery                 73
        node-centric CrimeSPOT: event dispatching, storage, matching
                                expiration, subsumption, causality, exceptions
     network-centric CrimeSPOT: untangles application logic from interaction rules
                                library of interaction rules

 validated expressiveness using 6 representative STADiUM applications (R.2.2.4)
     temperature monitoring, fire detection, flood monitoring, range coverage
     on average 0.22 mappings, 4.14 interaction rules, 3.72 component methods

 overhead
     ∆ROM: +460kB         ∆RAM: 3kB / fact, 30kB / worst-case rule with 6 conditions
     assertion latency: 30ms (LooCI event) 80ms (CrimeSPOT fact)
Conclusions
... and future work
language for programming WSN interactions
   minimizes accidental complexity so developer can focus on essential complexity
         node-centric: declarative rules specify interactions
      network-centric: which rules govern which components
      domain-specific: semantics for events that carry sensor readings

software engineering characteristics
         node-centric: interactions untangled from application logic
                       interaction rules straightforward to compose
      network-centric: library of network configurations

towards analyses for application-specific middleware modules (WP3.1)
   profile application with respect to network and memory usage
   explicit in code: expirations, intervals

More Related Content

Similar to The STADiUM language framework for capturing domain-specific interaction patterns

soft-shake.ch - Windows Phone 7 „Mango“ – what’s new for Developers?
soft-shake.ch - Windows Phone 7 „Mango“ – what’s new for Developers?soft-shake.ch - Windows Phone 7 „Mango“ – what’s new for Developers?
soft-shake.ch - Windows Phone 7 „Mango“ – what’s new for Developers?soft-shake.ch
 
Enabling Value Added Services in the Event-based Internet
Enabling Value Added Services in the Event-based InternetEnabling Value Added Services in the Event-based Internet
Enabling Value Added Services in the Event-based InternetYiannis Verginadis
 
Android. behind the scenes_programatica 2012
Android. behind the scenes_programatica 2012Android. behind the scenes_programatica 2012
Android. behind the scenes_programatica 2012Agora Group
 
Managing Cloud Security: Intrusion Detection Services in a Public Cloud
Managing Cloud Security: Intrusion Detection Services in a Public CloudManaging Cloud Security: Intrusion Detection Services in a Public Cloud
Managing Cloud Security: Intrusion Detection Services in a Public CloudRightScale
 
Mobile App Assurance: Yesterday, Today, and Tomorrow.
Mobile App Assurance: Yesterday, Today, and Tomorrow.Mobile App Assurance: Yesterday, Today, and Tomorrow.
Mobile App Assurance: Yesterday, Today, and Tomorrow.Bob Binder
 
Windows Azure Platform - The Color of Cloud Computing
Windows Azure Platform - The Color of Cloud ComputingWindows Azure Platform - The Color of Cloud Computing
Windows Azure Platform - The Color of Cloud ComputingGeorge Kanellopoulos
 
Tutorial on Constructing a Web-Server with Patterns at ADC 2004
Tutorial on Constructing a Web-Server with Patterns at ADC 2004 Tutorial on Constructing a Web-Server with Patterns at ADC 2004
Tutorial on Constructing a Web-Server with Patterns at ADC 2004 David Freitas
 
Emergency Services - Process+Rules+Events Rules Fest 2011
Emergency Services - Process+Rules+Events Rules Fest 2011Emergency Services - Process+Rules+Events Rules Fest 2011
Emergency Services - Process+Rules+Events Rules Fest 2011Mauricio (Salaboy) Salatino
 
Intrusion Alert Correlation
Intrusion Alert CorrelationIntrusion Alert Correlation
Intrusion Alert Correlationamiable_indian
 
Lap around windows azure
Lap around windows azureLap around windows azure
Lap around windows azureManish Corriea
 
Private cloud, the Good, the Bad and the Ugly
Private cloud, the Good, the Bad and the UglyPrivate cloud, the Good, the Bad and the Ugly
Private cloud, the Good, the Bad and the UglyTudor Damian
 
Dynamic Event-Driven Actors (DERA)
Dynamic Event-Driven Actors (DERA)Dynamic Event-Driven Actors (DERA)
Dynamic Event-Driven Actors (DERA)Huy Tran
 
Japan aws user group osaka study session #0 LT: DevOps
Japan aws user group osaka study session #0   LT: DevOpsJapan aws user group osaka study session #0   LT: DevOps
Japan aws user group osaka study session #0 LT: DevOpsHirokazu MORIKAWA
 
Correlation Architecture
Correlation ArchitectureCorrelation Architecture
Correlation Architecturesboray
 
Venus-c: Using open source clouds in eScience
Venus-c: Using open source clouds in eScienceVenus-c: Using open source clouds in eScience
Venus-c: Using open source clouds in eScienceOW2
 
Sa 005 performance
Sa 005 performanceSa 005 performance
Sa 005 performanceFrank Gielen
 
Restate: Event-driven Asynchronous Services, Easy as Synchronous RPC
Restate: Event-driven Asynchronous Services, Easy as Synchronous RPCRestate: Event-driven Asynchronous Services, Easy as Synchronous RPC
Restate: Event-driven Asynchronous Services, Easy as Synchronous RPCHostedbyConfluent
 
Ca today here and_now_martin_vajda
Ca today here and_now_martin_vajdaCa today here and_now_martin_vajda
Ca today here and_now_martin_vajdamvajda62
 

Similar to The STADiUM language framework for capturing domain-specific interaction patterns (20)

soft-shake.ch - Windows Phone 7 „Mango“ – what’s new for Developers?
soft-shake.ch - Windows Phone 7 „Mango“ – what’s new for Developers?soft-shake.ch - Windows Phone 7 „Mango“ – what’s new for Developers?
soft-shake.ch - Windows Phone 7 „Mango“ – what’s new for Developers?
 
Enabling Value Added Services in the Event-based Internet
Enabling Value Added Services in the Event-based InternetEnabling Value Added Services in the Event-based Internet
Enabling Value Added Services in the Event-based Internet
 
Android. behind the scenes_programatica 2012
Android. behind the scenes_programatica 2012Android. behind the scenes_programatica 2012
Android. behind the scenes_programatica 2012
 
Managing Cloud Security: Intrusion Detection Services in a Public Cloud
Managing Cloud Security: Intrusion Detection Services in a Public CloudManaging Cloud Security: Intrusion Detection Services in a Public Cloud
Managing Cloud Security: Intrusion Detection Services in a Public Cloud
 
Coca1
Coca1Coca1
Coca1
 
Mobile App Assurance: Yesterday, Today, and Tomorrow.
Mobile App Assurance: Yesterday, Today, and Tomorrow.Mobile App Assurance: Yesterday, Today, and Tomorrow.
Mobile App Assurance: Yesterday, Today, and Tomorrow.
 
Windows Azure Platform - The Color of Cloud Computing
Windows Azure Platform - The Color of Cloud ComputingWindows Azure Platform - The Color of Cloud Computing
Windows Azure Platform - The Color of Cloud Computing
 
Tutorial on Constructing a Web-Server with Patterns at ADC 2004
Tutorial on Constructing a Web-Server with Patterns at ADC 2004 Tutorial on Constructing a Web-Server with Patterns at ADC 2004
Tutorial on Constructing a Web-Server with Patterns at ADC 2004
 
Emergency Services - Process+Rules+Events Rules Fest 2011
Emergency Services - Process+Rules+Events Rules Fest 2011Emergency Services - Process+Rules+Events Rules Fest 2011
Emergency Services - Process+Rules+Events Rules Fest 2011
 
Intrusion Alert Correlation
Intrusion Alert CorrelationIntrusion Alert Correlation
Intrusion Alert Correlation
 
P106 rajagopalan-read
P106 rajagopalan-readP106 rajagopalan-read
P106 rajagopalan-read
 
Lap around windows azure
Lap around windows azureLap around windows azure
Lap around windows azure
 
Private cloud, the Good, the Bad and the Ugly
Private cloud, the Good, the Bad and the UglyPrivate cloud, the Good, the Bad and the Ugly
Private cloud, the Good, the Bad and the Ugly
 
Dynamic Event-Driven Actors (DERA)
Dynamic Event-Driven Actors (DERA)Dynamic Event-Driven Actors (DERA)
Dynamic Event-Driven Actors (DERA)
 
Japan aws user group osaka study session #0 LT: DevOps
Japan aws user group osaka study session #0   LT: DevOpsJapan aws user group osaka study session #0   LT: DevOps
Japan aws user group osaka study session #0 LT: DevOps
 
Correlation Architecture
Correlation ArchitectureCorrelation Architecture
Correlation Architecture
 
Venus-c: Using open source clouds in eScience
Venus-c: Using open source clouds in eScienceVenus-c: Using open source clouds in eScience
Venus-c: Using open source clouds in eScience
 
Sa 005 performance
Sa 005 performanceSa 005 performance
Sa 005 performance
 
Restate: Event-driven Asynchronous Services, Easy as Synchronous RPC
Restate: Event-driven Asynchronous Services, Easy as Synchronous RPCRestate: Event-driven Asynchronous Services, Easy as Synchronous RPC
Restate: Event-driven Asynchronous Services, Easy as Synchronous RPC
 
Ca today here and_now_martin_vajda
Ca today here and_now_martin_vajdaCa today here and_now_martin_vajda
Ca today here and_now_martin_vajda
 

More from Coen De Roover

A Recommender System for Refining Ekeko/X Transformation
A Recommender System for Refining Ekeko/X TransformationA Recommender System for Refining Ekeko/X Transformation
A Recommender System for Refining Ekeko/X TransformationCoen De Roover
 
A recommender system for generalizing and refining code templates
A recommender system for generalizing and refining code templatesA recommender system for generalizing and refining code templates
A recommender system for generalizing and refining code templatesCoen De Roover
 
Applicative Logic Meta-Programming as the foundation for Template-based Progr...
Applicative Logic Meta-Programming as the foundation for Template-based Progr...Applicative Logic Meta-Programming as the foundation for Template-based Progr...
Applicative Logic Meta-Programming as the foundation for Template-based Progr...Coen De Roover
 
Multi-dimensional exploration of API usage - ICPC13 - 21-05-13
Multi-dimensional exploration of API usage - ICPC13 - 21-05-13Multi-dimensional exploration of API usage - ICPC13 - 21-05-13
Multi-dimensional exploration of API usage - ICPC13 - 21-05-13Coen De Roover
 
Detecting aspect-specific code smells using Ekeko for AspectJ
Detecting aspect-specific code smells using Ekeko for AspectJDetecting aspect-specific code smells using Ekeko for AspectJ
Detecting aspect-specific code smells using Ekeko for AspectJCoen De Roover
 
Ekeko Technology Showdown at SoTeSoLa 2012
Ekeko Technology Showdown at SoTeSoLa 2012Ekeko Technology Showdown at SoTeSoLa 2012
Ekeko Technology Showdown at SoTeSoLa 2012Coen De Roover
 
A Logic Meta-Programming Foundation for Example-Driven Pattern Detection in O...
A Logic Meta-Programming Foundation for Example-Driven Pattern Detection in O...A Logic Meta-Programming Foundation for Example-Driven Pattern Detection in O...
A Logic Meta-Programming Foundation for Example-Driven Pattern Detection in O...Coen De Roover
 
The SOUL Tool Suite for Querying Programs in Symbiosis with Eclipse
The SOUL Tool Suite for Querying Programs in Symbiosis with EclipseThe SOUL Tool Suite for Querying Programs in Symbiosis with Eclipse
The SOUL Tool Suite for Querying Programs in Symbiosis with EclipseCoen De Roover
 
Logic-based program transformation in symbiosis with Eclipse
Logic-based program transformation in symbiosis with EclipseLogic-based program transformation in symbiosis with Eclipse
Logic-based program transformation in symbiosis with EclipseCoen De Roover
 

More from Coen De Roover (9)

A Recommender System for Refining Ekeko/X Transformation
A Recommender System for Refining Ekeko/X TransformationA Recommender System for Refining Ekeko/X Transformation
A Recommender System for Refining Ekeko/X Transformation
 
A recommender system for generalizing and refining code templates
A recommender system for generalizing and refining code templatesA recommender system for generalizing and refining code templates
A recommender system for generalizing and refining code templates
 
Applicative Logic Meta-Programming as the foundation for Template-based Progr...
Applicative Logic Meta-Programming as the foundation for Template-based Progr...Applicative Logic Meta-Programming as the foundation for Template-based Progr...
Applicative Logic Meta-Programming as the foundation for Template-based Progr...
 
Multi-dimensional exploration of API usage - ICPC13 - 21-05-13
Multi-dimensional exploration of API usage - ICPC13 - 21-05-13Multi-dimensional exploration of API usage - ICPC13 - 21-05-13
Multi-dimensional exploration of API usage - ICPC13 - 21-05-13
 
Detecting aspect-specific code smells using Ekeko for AspectJ
Detecting aspect-specific code smells using Ekeko for AspectJDetecting aspect-specific code smells using Ekeko for AspectJ
Detecting aspect-specific code smells using Ekeko for AspectJ
 
Ekeko Technology Showdown at SoTeSoLa 2012
Ekeko Technology Showdown at SoTeSoLa 2012Ekeko Technology Showdown at SoTeSoLa 2012
Ekeko Technology Showdown at SoTeSoLa 2012
 
A Logic Meta-Programming Foundation for Example-Driven Pattern Detection in O...
A Logic Meta-Programming Foundation for Example-Driven Pattern Detection in O...A Logic Meta-Programming Foundation for Example-Driven Pattern Detection in O...
A Logic Meta-Programming Foundation for Example-Driven Pattern Detection in O...
 
The SOUL Tool Suite for Querying Programs in Symbiosis with Eclipse
The SOUL Tool Suite for Querying Programs in Symbiosis with EclipseThe SOUL Tool Suite for Querying Programs in Symbiosis with Eclipse
The SOUL Tool Suite for Querying Programs in Symbiosis with Eclipse
 
Logic-based program transformation in symbiosis with Eclipse
Logic-based program transformation in symbiosis with EclipseLogic-based program transformation in symbiosis with Eclipse
Logic-based program transformation in symbiosis with Eclipse
 

Recently uploaded

Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAndikSusilo4
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetEnjoy Anytime
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 

Recently uploaded (20)

Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your BudgetHyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
Hyderabad Call Girls Khairatabad ✨ 7001305949 ✨ Cheap Price Your Budget
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Vulnerability_Management_GRC_by Sohang Sengupta.pptx
Vulnerability_Management_GRC_by Sohang Sengupta.pptxVulnerability_Management_GRC_by Sohang Sengupta.pptx
Vulnerability_Management_GRC_by Sohang Sengupta.pptx
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 

The STADiUM language framework for capturing domain-specific interaction patterns

  • 1. Coen De Roover Christophe Scholliers Software Languages Lab, Brussels Wouter Amerijckx The STADiUM language framework for capturing domain-specific interaction patterns
  • 2. Motivating Example ... SE problems associated with event-based programming Tent C Tent B Tent A Component: subscribed to single event Component: HumiditySensor TemperatureSensor Component: receiveEvent(Event e) { online HeatingController // invoke application logic online temperatureReading online // publish new event humidityReading adjustHeating } Decentralized Event Bus difficult to compose event handlers online humidityReading adjustHeating temperatureReading subscribed to multiple events Component: dispatch over received events ComfortLevelMonitor manage state (event sequences) relate events through matching
  • 3. Motivating Example ... problems inherent to the STADiUM domain Tent C Tent B Tent A compensate reactions to stale readings Component: TemperatureSensor Component: HumiditySensor Component: state changes HeatingController online online context-dependent behavioral adaptions temperatureReading online humidityReading adjustHeating Decentralized Event Bus online adjustHeating humidityReading events carry sensor readings temperatureReading readings expire Component: ComfortLevelMonitor readings subsume others application-specific: time, content, origin
  • 4. CrimeSPOT in a Nutshell ... a domain-specific language for programming WSN interactions minimize accidental complexity so developers can focus on essential complexity m atch sub sume node-centric perspective dispatch expir e compensate specify interactions declaratively ement state manag network-centric perspective specify which rules govern which components configurable runtime application-specific semantics of events
  • 5. nod The CrimeSPOT runtime cen e- ... architectural overview tric CrimeSPOT runtime inference engine Inference Layer evaluates rules against facts Fact Inference Rule tracks causality Base Engine Base Reification Layer reification engine Reification Configuration reifies events as facts Engine Base expiration and subsumption Infrastructure Layer Middleware Bridge Middleware Bridge middleware bridge transfers events to and from bus bridge to LooCI
  • 6. nod Distributed Interaction Rules cen e- ... publishing facts on the network tric fact in fact base temperatureReading(Celsius=27)@[factExpires(Seconds=600)] matching condition in rule celsiusReading(Celsius=?value)@[to(Mac=*)] ← temperatureReading(Celsius=?value)
  • 7. nod Distributed Interaction Rules cen e- ... invoking application logic tric from body of rule e.g., unicast a reading upon a request humidityReading(Percent=?p)@[to(MAC=?mac, ID=?id)] ← requestForHumidity()@[from(MAC=?mac, ID=?id)], ?p is this.getHumidity() e.g., broadcast a reading at set intervals humidityReading(Percent=?p)@[to(MAC=*),factExpires(Seconds=600)] ← ?p is this.getHumidity()@[renewEvery(Seconds = 600)]
  • 8. nod Distributed Interaction Rules cen e- ... invoking application logic tric in head of rule e.g., a state change that has to be undone this.adjustHeater ← adjustHeating(Level=?h) class HeatingController private CSAction adjustHeater = new CSAction() { public void activated(CSVariableBindings bindings) { //adjust heating } public void deactivate(CSVariableBindings bindings) { //reset heating } }; }
  • 9. nod Reifying Events as Facts cen e- ... fine-tuning the reification engine tric mapping LooCI events to CrimeSPOT facts Configuration Base Decentralized Event Bus Middleware Reification Fact Event Fact Bridge Engine Base Event Drop? Subsumes? Assert Reification e.g., temperature readings mapping temperatureReading(Celsius=?temp)@[factExpires(Seconds=600)] <=> Event_101(Integer=?temp).
  • 10. nod Reifying Events as Facts cen e- ... fine-tuning the reification engine tric controlling fact subsumption e.g., a humidity reading subsumes others from same tent incoming humidityReading(Percent=?new)@[from(ID=?id)] subsumes humidityReading(Percent=?old)@[from(ID=?otherid)] provided online(Tent=?tent)@[from(ID=?id)], online(Tent=?tent)@[from(ID=?otherid)]
  • 11. net WSN Application as a Whole wo cen rk- ... which CrimeSPOT code goes where? tric quantify over components enumerate rules and supporting code e.g., tent-related code shared by all components *{ online(Tent=?tnt)@[to(MAC=*),factExpires(Seconds=3600)] ← ?tnt is this.getTentBasedOnGPSReading()@[renewEvery(Seconds=3600)]. } *.java { private CSValue getTentBasedOnGPSReading() { return ... } }
  • 12. net WSN Application as a Whole wo cen rk- ... reusing CrimeSPOT code tric macro definition and application ComfortLevelMonitor { subsumesOlderFromSameTent(humidityReading,Percent). subsumesOlderFromSameTent(temperatureReading,Celsius). } * { defmacro subsumesOlderFromSameTent($reading,$type): incoming $reading($type =?new)@[from(ID=?id)] subsumes $reading($type =?old)@[from(ID=?otherid)] provided online(Tent=?tent)@[from(ID=?id)], online(Tent=?tent)@[from(ID=?otherid)] }
  • 13. Motivating Example Revisited ... lines of CrimeSPOT code for the entire WSN Application 73
  • 14. Motivating Example Revisited ... TemperatureSensor and HumiditySensor components 1. TemperatureSensor,  HumiditySensor,  HeatingController  { 2.        publishPresenceEvery($onlineInterval). 3. } 4. TemperatureSensor  { 5.        temperatureMapping($readingInterval).         6.        temperatureReading(Celsius=?temp)@[to(MAC=*), 7.                                                                              factExpires($readingInterval)]   8.            <-­‐  ?temp  is  this.getTemperature()@[renewEvery($readingInterval)]. 9.  } 10.   11.  TemperatureSensor.java  { 12.        private  CSValue  getTemperature()  {  return  ...  } 13.  } 14.  HumiditySensor  { 15.        humidityMapping($readingInterval). 16.        humidityReading(Percent=?p)@[to(MAC=*), 17.                                                                  factExpires($readingInterval)] 18.          <-­‐  ?p  is  this.getHumidity()@[renewEvery($readingInterval)]   19.  } 20.   21.  HumiditySensor.java  { 22.        private  CSValue  getHumidity()  {  return  ...  } 23.  }
  • 15. Motivating Example Revisited ... component HeatingController 24. HeatingController  { 25.        incoming  adjustHeating(Level=?new)  subsumes  adjustHeating(Level=?old). 26.             27.        this.adjustHeater 28.            <-­‐  adjustHeating(Level=?h). 29. } 30.   31. HeatingController.java  { 32.    private  CSAction  adjustHeater  =  new  CSAction()  { 33.          public  void  activated(CSVariableBindings  bindings)  {  //adjust  heating  } 34.          public  void  deactivate(CSVariableBindings  bindings)  {  //reset  heating  } 35.    };     36. }
  • 16. Motivating Example Revisited ... component ComfortLevelMonitor 37.    ComfortLevelMonitor  {   38.        temperatureMapping($readingInterval). 39.        humidityMapping($readingInterval). 40.        subsumesOlderFromSameTent(humidityReading,Percent). 41.        subsumesOlderFromSameTent(temperatureReading,Celsius). 42.        incoming  online(Tent=?tnt,Component=?c)@[from(MAC=?m)]   43.        subsumes  online(Tent=?otnt,Component=?c)@[from(MAC=?m)].       44.                         45.        this.logComfortLevel 46.            <-­‐  humidityReading(Percent=?h)@[from(MAC=?hm,ID=?hi)],               47.                  temperatureReading(Celsius=?t)@[from(MAC=?tm,ID=?ti)], 48.                  online(Tent=?tnt)@[from(MAC=?hm,ID=?hi)], 49.                  online(Tent=?tnt)@[from(MAC=?tm,ID=?ti)]. 50.             37.        adjustHeating(Level=?heatingLevel)@[to(MAC=?hcm,ID=?hci), 38.                                                                                factExpires($readingInterval)] 39.            <-­‐  temperatureReading(Celsius=?t)@[from(MAC=?tm,ID=?ti)], 40.                  online(Tent=?tnt)@[from(MAC=?tm,ID=?ti)], 41.                  ?heatingLevel  is  this.computeHeatingLevel((Number)?t), 42.                  online(Component=`HeatingController,Tent=?tnt)@[from(MAC=?hcm,ID=?hci)].   43.    }   44.   45.    ComfortLevelMonitor.java  { 46.      private  CSValue  computeHeatingLevel(Number  t)  {  return  ...  } 47.  }
  • 17. Motivating Example Revisited ... code shared by all components 48.  *.java  { 49.        private  CSValue  getTentBasedOnGPSReading()  {  return  ...  } 50.  } 51.   52.  *  {         53.        defvar  $readingInterval:  Seconds=600. 54.        defvar  $onlineInterval:  Seconds=3600. 55.   56.        defmacro  temperatureMapping(): 57.                mapping  temperatureReading(Celsius=?temp)@[factExpires($readingInterval)]   58.            <=>  Event_101(Integer=?temp). 59.                   60.        defmacro  humidityMapping(): 61.                mapping  humidityReading(Percent=?h)@[factExpires($readingInterval)]   62.            <=>  Event_102(Integer=?h). 63.   64.        defmacro  publishPresenceEvery($time): 65.              online(Tent=?tnt,Component=`$COMPONENT_NAME)@[to(MAC=*),factExpires($time)]     66.                    <-­‐  ?tnt  is  this.getTentBasedOnGPSReading()@[renewEvery($time)]. 67.                   68.        defmacro  subsumesOlderFromSameTent($reading,$type): 69.              incoming  $reading($type=?new)@[from(MAC=?mac)] 70.              subsumes  $reading($type=?old)@[from(MAC=?othermac)] 71.              provided  online(Tent=?tnt)@[from(MAC=?mac)], 72.                online(Tent=?tnt)@[from(MAC=?othermac)]. 73.  }
  • 18. Evaluation ... using CrimeSPOT on top of LooCI on SunSPOT motes 73 lines of code for motivating example LooCI: component deployment, wiring event routing, service discovery 73 node-centric CrimeSPOT: event dispatching, storage, matching expiration, subsumption, causality, exceptions network-centric CrimeSPOT: untangles application logic from interaction rules library of interaction rules validated expressiveness using 6 representative STADiUM applications (R.2.2.4) temperature monitoring, fire detection, flood monitoring, range coverage on average 0.22 mappings, 4.14 interaction rules, 3.72 component methods overhead ∆ROM: +460kB ∆RAM: 3kB / fact, 30kB / worst-case rule with 6 conditions assertion latency: 30ms (LooCI event) 80ms (CrimeSPOT fact)
  • 19. Conclusions ... and future work language for programming WSN interactions minimizes accidental complexity so developer can focus on essential complexity node-centric: declarative rules specify interactions network-centric: which rules govern which components domain-specific: semantics for events that carry sensor readings software engineering characteristics node-centric: interactions untangled from application logic interaction rules straightforward to compose network-centric: library of network configurations towards analyses for application-specific middleware modules (WP3.1) profile application with respect to network and memory usage explicit in code: expirations, intervals