For example, fetched data are first routed to selections to
filter, then the filtered data are aggregated by the aggregate operator (if
it exists).
??? Subtree result message handling. When a result arrives from a neighbor,
this result needs to be integrated into the aggregate values being computed
locally. If the result corresponds to an aggregate query, that result or the
received data is forwarded up along the routing tree towards the root.
(3) Memory Manager
TinyDB Memory Manager allocates memory and stores data compactly
(to save storage space). It can move memory around in the frame without
changing all the external references.
(4) Network Topology Manager
325
Jinbao Li, Zhipeng Cai, and Jianzhong Li
The Network Topology Manager handles all the mote-to-mote and moteto-
base-station communication for TinyDB, that is routing query and data
messages. Most of the code in this component manages the network topology.
The network topology is maintained as a routing tree, with Mote #0 at the
root. As a rule, query messages flood down the tree in a straightforward
fashion. Data messages flow back up the tree, participating in more complex
query processing algorithms. Mote #0 passes result data to the end user or
applications.
By default, a simple tree-maintenance algorithm is used. This algorithm
has each mote keep track of a list of other motes from which it receives messages
(neighbors). Among these neighbors, it chooses the best one as its parent
in the tree.
Pages:
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523