Skip to Main Content
In wireless sensor networks, users often submit spatial window aggregation queries to obtain the summary information about a local area in the monitored region, for example, "retrieving the average temperature from region A.". The current state-of-the-art spatial window aggregation query processing algorithms do not take sensor node failures into consideration, which leads to low query success rate and high energy consumption. In order to solve this problem, we propose an algorithm called RSA (energy-efficient and robust spatial window aggregation query processing algorithm) in this paper, which takes advantage of sensor node redundancy to ensure the robustness of query processing. It divides the query area into several grid cells and collects the sensor readings of nodes within each grid cell along an itinerary. Each grid cell has a cluster head node which collects the sensory data of nodes in the grid cell, calculates the partial query result and sends the result to the cluster head node of the next grid cell. This procedure is repeated until traversing all the grid cells within the query area. RSA can ensure that all non-cluster-head nodes in each grid cell can derive partial query result independently in addition to the cluster head node. Therefore, it can return query result successfully, unless all nodes in a grid cell fail simultaneously. We also deduce the energy consumption formula of RSA according to which the setting of grid cell size and electing of cluster head node are optimized to reduce the energy consumption. Through extensive simulations, we show that RSA outperforms the existing algorithms in terms of query success rate and energy consumption in most cases.