5 ms·
Actually, the core CDB data structure only limits keys and values to 4GB each, not in total: http://www.unixuser.org/~euske/doc/cdbinternals/index.html http://
by rcoder 17y ago
Actually, the core CDB data structure only limits keys and values to 4GB each, not in total:
http://www.unixuser.org/~euske/doc/cdbinternals/index.html http://www.unixuser.org/~euske/doc/cdbinternals/index.html
The hash algorithm used also only produces a 32-bit key, meaning you'll be limited to 2^32 total records. Again, though, unless your data is of trivial size, that gives you considerably more room to work with than a hard 4GB limit.
Edit: doh! can't use double-asterisk for exponent on HN
- deleted 17y ago[deleted]
- epi0Bauqu 17y agoThen why does the Perl implementation (http://search.cpan.org/~msergeant/CDB_File-0.96/CDB_File.pm http://search.cpan.org/~msergeant/CDB_File-0.96/CDB_File.pm) warn of the error: CDB database too large -- You attempted to create a cdb file larger than 4 gigabytes. ?
- asb 17y agoI believe rcoder is saying the 4GB database limit is a property of the implementation rather than the cdb format.