- Go 100%
cdb
This is a "pure Go" implementation of "Constant Database" as described by D. J. Bernstein under http://cr.yp.to/cdb.html.
This is a read-only, disk-based, key-value store. The implementation embedded in the program. There is no need to have a client/server architecture.
The advantages are described D. J. Bernstein. But what people care the most are fast-look up (at most two disk accesses per lookup) and low overhead (2kib of metadata per database + 24b per records).
One of the limitation of cdb database is their 4GiB limit, since they store 32 bits positions pointers. This can be consider an advantage for SoC and embedded devices development.
The database is create with initial data once, and read-only. Some use cases include blazing fast static HTTP.
This is an alternative implementation to github.com/jbarham/cdb. For the following reason:
-
J. Barham's Go CDB implementation heavily uses
panic()andrecover()which is officially an "approved" method to handle errors, however it makes, IMHO, the code hard to follow. -
J. Barham's Go CDB implementation copy the original cdb, especially for Dump. This tools offers more generic interfaces/methods.