Alternative to BerkeleyDB?

前端 未结 9 1082

I\'m looking for a dbm-like library that I can use in place of Berkeley DB, which I\'m currently using. My main reason for switching is the licensing fees for BDB are pretty hig

相关标签:
9条回答
  • 2021-01-30 03:10

    Firebird is your best friend.

    0 讨论(0)
  • 2021-01-30 03:14

    SQLite is public domain, meaning you can use it for any purpose whatsoever, and is widely used and supported.

    0 讨论(0)
  • 2021-01-30 03:16

    You can get much improved performance out of any dbm (even qdbm) and improved parallelism with a simple level of indirection: Simply take your keys and hash them, and use data_dir/H(key)/ as the database to store those keys. Limit the hash output to a small value (say) 255 for best results.

    This approach has a number of benefits, easily summarized:

    • Conceptually simple
    • Easy to implement and test
    • Doesn't lock the entire database for updates
    • Can support much larger databases
    • Easy to replace the DBM component

    The hash probably doesn't even need to be cryptographically secure; just mostly uniform. DJB's cdb hash works well in most cases.

    0 讨论(0)
提交回复
热议问题