Access methods

BangDB implements two types of data structure methodology to implement indexes for keys in order to retrieve the data quickly, and they are;
BangDB actually implements varient of Btree, namely B-link-Tree tree based mostly on Lehman and Yao's "Efficient Locking for Concurrent Operations on BTrees".The BangDB's implementation has worked on the concept defined in the paper and has taken it further to enhance the performance by increasing the concurrency significantly.
BangDB also does selective caching of few highly accessed pages and related information to improve the performance.
The main highlight of Btree for BangDB are;
When to use Btree
Btree should be used for storing data when order is important. For example, to be able to retrieve data using range scan or query, it's very important that keys are sorted and stored in the order such that the range based selection can be done.
BangDB implements the variation of hash, namely extending hashing based mostly on Hsu and Yang's "Concurrent Operations in Extendible Hashing". The BangDB's implementation has worked on the concept defined in the paper and has taken it further to enhance the performance by increasing the concurrency.
BangDB also does selective caching of few highly accessed pages and related information to improve the performance.
The main highlight of ExtHash for BangDB are;
When to use Hash
Hash should be used for storing data when order of the keys are not important. Note that the scan API can be used for hash based table as well but the range based scan is not possible. This means that user can use scan to select all the keys and values from the db and iterate over them but they can't provide any range for scan as it would be meaningless since hash doesn't maintain any order.