Bamboo Filters: Make Resizing Smooth and Adaptive
Hancheng Wang,Haipeng Dai,Shusen Chen,Meng Li,Rong Gu,Huayi Chai,Jiaqi Zheng,Zhiyuan Chen,Shuaituan Li,Xianjun Deng,Guihai Chen
DOI: https://doi.org/10.1109/tnet.2024.3403997
2022-01-01
Abstract:The approximate membership query (AMQ) data structure is a kind of space-efficient probabilistic data structure. It can approximately indicate whether an element exists in a set. The AMQ data structure has been widely used in network measurements, network security, network caching, etc. Resizing is an extensively utilized operation of the AMQ data structure, but it can lead to system performance degradation. We summarize two main problems that lead to such degradation. Specifically, one of them is that the resizing operation can block other operations, while the other one is that the throughput of AMQ structures will deteriorate after multiple resizing operations due to more computation cost. However, existing related work cannot alleviate both of them. Therefore, we propose a novel AMQ data structure called bamboo filters, which can alleviate the two problems simultaneously. Bamboo filters can insert, look up, and delete an element in constant time. They can also dynamically resize in a fine-grained way. Furthermore, we propose space utilization adaptive bamboo filters that adaptively trigger resizing operations according to the space utilization, thereby achieving lower average memory consumption. Experimental results show that our scheme significantly outperforms state-of-the-art work. Especially, bamboo filters achieve $2.12\times $ lookup throughput of the logarithmic dynamic cuckoo filter.