timshannon / bolthold

BoltHold is an embeddable NoSQL store for Go types built on BoltDB
MIT License
643 stars 45 forks source link

Badger support #41

Closed jackprophesy closed 5 years ago

jackprophesy commented 5 years ago

Love this. Any plans for badger support? Anything you know of that would make it difficult to port? Thx.

timshannon commented 5 years ago

Yeah, I'd definitely love to add badger support. I've been debating whether or not to make it a separate library.

I think I'll see if I can integrate it without too much having to change.

nkev commented 5 years ago

+1 "Badgerhold" would go off, me thinks.

ghost commented 5 years ago

+1 for badger. Bolt has blocking transactions(so you have to do batches to get sane performance) whereas badger does not. My latest testing was 250 bolt transactions vs 15 000 badger transactions per second.

timshannon commented 5 years ago

Alright I've opened up a new repository where I'll start on BadgerHold:

https://github.com/timshannon/BadgerHold

Follow the repo there for updates.

timshannon commented 5 years ago

I'm closing this issue, as BadgerHold looks ready for use currently. The master branch passes all tests, although there is one outstanding issue that I'm still working through, and hope to get resolved shortly.

I've also written up a comparison between BoltDB and Badger since I've had the opportunity to implement the exact same library on both databases.

https://tech.townsourced.com/post/boltdb-vs-badger/

nkev commented 5 years ago

@timshannon Great article. I'm surprised about Badgers high memory consumption. My plan was to use multiple badger instances (one for each customer), but now I think I'll go back to BoltDB.

timshannon commented 5 years ago

You should read the exchange here: https://github.com/dgraph-io/badger/pull/704#issuecomment-459080457

The Dgraph guys themselves, don't seem to have any issues running multiple instances, so you might want to do your own testing to confirm for yourself.