Title: SwissQM Nextgeneration Data Processing in Sensor Networks
1SwissQMNext-generation DataProcessing in Sensor
Networks
Some of the slides are from the authors René
Müller, Gustavo Alonso, and Donald
Kossmann Department of Computer Science, ETH
Zurich
2Outline
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
3Introduction(1)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Wireless Sensor Networks
- Collection of Sensor Nodes
- Sensor Node
- A Processor
- A Radio Unit
- A bunch of Sensors
- A Battery
- Ad Hoc Networks
4Introduction(2)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Sensor Network Applications
Structural monitoring
agriculture
Urban warfare
5Introduction(3)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Typical Application Scenario
- Distribute a number of sensor nodes that measure
property X. - Add a PC/PDA/ that will record the measured
data. - Connect a the PC/PDA/ with one sensor.
- Nodes build an Ad-hoc Network (e.g., routing
tree). - Let them send (periodically) along tree to the
PC/PDA/
6Motivation(1)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Limited Resource of Sensor Nodes
- Flash-Memory, RAM, Radio, Battery
- Programming on Sensor Nodes for Data Processing
- In practice very low-level
- The dirty way NesC, TinyOS, etc.
- The refined way Queries (TinyDB/Cougar like)
- Very platform/target specific
- Cumbersome
- Professional Debugging
- Only 3 LEDs for status information of the program
- Expensive debugging kits (e.g. JTAG) lead to
inner workings of processor
7Motivation(2)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- We needed something better!
- Something Like a System
- Language independent (SQL, XQuery, Java, new
languages, Webservices ) - Turing complete (can compute every
Turing-computable function) - User-defined functions
- Capable of pushing down complex processing
functions all the way to the sensors
8Motivation(3)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Solution
- Virtual Machine tailored to data acquisition in
sensor networks - Virtual Machine Example JVM
9SwissQM
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Scalable WIreleS Sensor Query Machine
10SwissQM Overview
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Design Considerations
- Sensor Network Gateway
- SwissQM On The Sensor Node
- SwissQM Programs
- Bytecode Instructions
- Multi-programming
- Messaging In The Network
- In-network Aggregation
- Program Propagation
11SwissQM(1)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Design Considerations
- Separation of sensors and external interface
- Language-independent
- No application specific functionality in sensors
- Dynamic, multi-user, multi-programming
environment - No imposed restrictions on the query submission
and the number of queries running concurrently - Optimized use of the sensors
- The sensors only process capturing, aggregating,
forwarding data. - Extensibility
- Allow user defined functions
- Possible to extend itself dynamically as needed
12SwissQM(2)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Sensor Network Gateway
- Be exploited as much as possible
- Everything that can be done at the gateway is
done - Provide all external interfaces query
optimisation and compiltion facilities
13SwissQM(3)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Outlook of SwissQM Gateway System
14SwissQM(4)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- SwissQM is a Virtual Machine on sensor node
- Virtual Machine
- Instruction Set
- Elementary Instruction Application-specific
extension - Functionality can be implemented
- In bytecode
- As additional instruction
15SwissQM(5)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Stack-based VM
- Integer Arithmetic ONLY
- 59 bytecode instructions
- 40 VM core
- 19 sensor network specific
- Transmission Buffer
- Buffer the data received and the data to be sent
- Synopsis
- Store the aggregation state
- Merge the data from its children and the data
itself - Sensor Interface
16SwissQM(6)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- SwissQM Programs
- Written in SwissQM bytecode (Java-like)
- Streaming data
- Consists of 3 sections
- Init section program initialization
- Delivery section invoked periodically
- Reception section called when data received from
children
17SwissQM(7)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Bytecode Instructions
- VM Instructions
- 16 Stack Instructions
- 11 Arithmetic and Logical Instructions
- 13 Control Instructions
- SwissQM Core Instructions
- 9 Buffer Instructions
- 7 Sensor Instruction
- 2 Transmission Instructions
- Application-specific
- 1 In-network Aggregation
18SwissQM(8)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
19SwissQM(9)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Multi-programming
- Support on two layers
- Merge different user queries into a virtual query
- Multi-programming in the QM
- In one sampling interval, sequentially execute
programs - Sample periods in the order of seconds
- Data transmission in the order of
milliseconds - Program execution in the order of microseconds
- Trade-off
- Number of programs VS Memory available for each
program - Can run over hundred user queries
20SwissQM(10)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Messaging in the Network
- Message Types
- Program Messages
- Result Messages
- Command Messages (Node Reset, Program Stop,)
- Traffic Pattern
- Root to all Program and Command Messages
- All to Root Result Messages
- Local Broadcasts Routing updates and time
synchronisation
21SwissQM(11)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- In-network Aggregation
- In-network aggregation can reduce the number of
messages (save energy) - TAG Approach Tiny AGgregation Madden OSDI02
- Example What is the average temperature in the
network?
22SwissQM(12)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- State of AVERAGE aggregation
- Sum
- Count
- In-network aggregation
- Tree topology
- Only one message per link
- Children send data before parent
(Scheduling/Timesync)
23SwissQM(13)
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- Program Propagtion
- Restricted message size in ad-hoc sensor
networks. - TinyDB uses 49 bytes message size but large data
losses are observed in its deployments - SwissQM opts for the smaller 36 bytes message
size and fragment messages are supported. - Use the same protocol as TinyDB in default.
24Application Examples
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
Example 1 Get the nodeid of the node whose
temperature exceeds 60?
- QM program
- .section delivery, _at_10s
- get_temp read temperature sensor
- ipushb 60
- if_icmple end skip if templt60
- get_nodeid read nodes ID
- istore 0 store it at pos. 0
- send_tb send transmission buffer
- end
- .section reception
- send_tb forward tuple from child
25Application Examples
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
Example 2 Assume that Light Sensor only produces
unprocessed raw values from the A/D converter and
light sensor has an offset reading that needs to
be accounted for. Goal Average temperature
readings of sensor nodes that have similar
brightness readings.
26Conclusions and Future Work
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- SwissQM
- Flexible programming platform for data
acquisition tasks in sensors networks - Offers a well defined and extensible bytecode
language - Can be used as compilation target for higher
programming and query languages (XQuery, SQL) - Increases abstraction level at the network
interface - Powerful instruction set -gt short programs -gt
eases dissemination - Future Work
- Future Sensor
- May have more memory and CPU power
- But radio bandwidth and reliability still an
issue - Cost-efficiency
- XML and XQuery support
27As a Reviewer
- Background Introduction
- Motivation
- A Solution SwissQM
- Application Examples
- Conclusions and Future Work
- As a Reviewer
- SwissQM v.s TinyDB
- Borrows many ideas from TinyDB, but improved a
lot due to the design
- Seems too little evaluations on the performance
- Itll be more convincing If they did a long-term
experiment to evaluate the performance of running
TinyDB on top of SwissQM compared with running
TinyDB itself
28End