Docstoc

Query Processing in Sensor Network

Document Sample
Query Processing in Sensor Network Powered By Docstoc
					                                                                                              Contents
                                                                      Problem
         Query Processing in                                          Sensor network database systems
          Sensor Network                                              Architecture
                                                                      The SQL-style interface
                                                                          SQL-
                         Daniel Nyberg                                The network structure
                    daniel.nyberg@ide.hh.se                           The query process
                                                                      Optimization techniques
                                                                      Future work
2005-05-10                  CES - Halmstad University         1   2005-05-10                   CES - Halmstad University                 2




                           Problem                                 Sensor network database systems
                                                                      Cougar
    How do we store data in a sensor network?                              Cornell University
    Use a warehouse                                                        Preserve traditional database abstraction but increase the
                                                                           efficiency
         Each sensor send data to a central node
         May use traditional DB system on that node                   TinyDB
                                                                           MIT
         May takes too much node capacity
                                                                                     in-
                                                                           Supportes in-network aggregation processing
             Unnecessary transmitting => Energy consumption
                                                                      Common for both
                                                                           SQL-
                                                                           SQL-style interface
    Let the network be the database!                                       Distributed executing queries
                                                                      No clear lines between these
2005-05-10                  CES - Halmstad University         3   2005-05-10                   CES - Halmstad University                 4




                       Architecture                                            The SQL-style interface
    Server side                                                       SQL-
                                                                      SQL-like language (Cougar and TinyDB)
         The base station                                                  Differ from traditional SQL
         Parses the user’s query                                           Queries are continuous and periodic
         Optimizes the query (optimization phase) and                      The way to execute is essential
                                                                           An optimization phase determine the best way to
         Deliver it into the sensor network                                execute a query (execution plan)
    Sensor side                                                            Example:
         Running on the sensor nodes                                           ”SELECT nodeid, light, temp FROM sensors, SAMPLE
                                                                               PERIOD 1s FOR 10s”
         Executes the query
                                                                               Gets the id of each node together with its measure for
         Returns the result to the base station                                light and temperature, once per second, for ten seconds
2005-05-10                  CES - Halmstad University         5   2005-05-10                   CES - Halmstad University                 6
               The network structure                                                             The query process
    Network structure (Cougar and TinyDB)                                         Query transmits via the routing tree to all nodes
                                   (tree-
         Nodes connected as a tree (tree-based routing)
         A root node – communicates with the base station                         Each node processes the query locally
             Root node has level 1                                                     Collect the set of sample data correspong to the
             Root nodes children has level 2                                           attributes in the query
             ...
         Nodes within the same level do not communicate with each                      Each data sample applies to the execution plan
         other
                                                                                  Data that passes the execution plan delivers to
         Parents are responsible for their children
         The structure may change (moving nodes, nodes run out of                 the parent node
         power, new nodes appear)                                                 The parent node may repeate the execution plan
         TinyDB has a list of parant candidates – change parent if link
         quality sufficient much lower                                            with the data from its children together with its
         Cougar has a similar mechanism                                           own data
2005-05-10                      CES - Halmstad University                7    2005-05-10                      CES - Halmstad University                  8




             Optimization techniques                                                       Optimization techniques
    Lifetime clause                                                               Pushing computation
         Specifies the duration of a query                                             Move the query processing (aggregation) into the
         Adjusts sample rate to fulfill duration time                                  network
         In TinyDB: Estimation at the base station                                     Aggregation techniques
         More efficient if performed periodically in network                               partial aggregation
                                                                                              Only collect sufficient data to produce the final result
                                                                                           packet merging
                                                                                              Concatenate several packets to only one larger packet
                                                                                              Avoid multiple headers



2005-05-10                      CES - Halmstad University                9    2005-05-10                      CES - Halmstad University                  10




             Optimization techniques                                                                    Future work
    Cross-
    Cross-layer interaction                                                       Find clear lines between Cougar and TinyDB
         Interact with network layer                                              Discuss comparation between these and the
         Intercept packets from being automatic forwarded                         warehouse approach in one or two application
         by network layer                                                         scenarios
         Is needed by the packet merging technique
         Cougar: Using network filters
             A set of functions which may modify or delete a packet
         In TinyDB: Collapsed the whole network stack
             Gives the application layer full control of network layer

2005-05-10                      CES - Halmstad University                11   2005-05-10                      CES - Halmstad University                  12

				
DOCUMENT INFO
Shared By:
Categories:
Tags:
Stats:
views:6
posted:11/21/2011
language:English
pages:2