top | item 3622895

(no title)

xxqs | 14 years ago

Did you compare the performance with (local) BerkeleyDB?

Also, is there a locking mechanism?

I'm the author of Torrus (torrus.org), and BerkeleyDB stability and non-network nature are quite painful. But I'm relying on its speed, concurrent locking, and some ways to acquire an exclusive lock on a table. It would be interesting to offer an alternative backend for torrus.

discuss

order

rescrv|14 years ago

I'm not sure exactly what you're looking for, but Berkeley DB is embedded in your application on a single host, while HyperDex is distributed. It sounds like that's exactly what you want.

What do you use exclusive locks for?

xxqs|14 years ago

I use exclusive locks where multiple processes concur for data access, and these locks guarantee the data consistency.

For example, the GUI engine may eventually start cleaning its old cache, and the exclusive lock prevents other GUI processes (which are mod_perl or fcgi processes) to do the same.

another example is when the database is big enough, and when multiple collector processes start at the same time, I use the exclusive lock to let them initialize and slurp the data sequentially: this prevents from excessive disk seeks.

but as you mentioned in another thread, your solution is locked to a single architecture, and I cannot afford that.

xxqs|14 years ago

and yes you're certainly right that BDB is embedded into the application process. Then any slight memory corruption may destroy the database and lockup the whole service. We've seen that, especially with graphics libraries.

But BDB offers tremendous speed, so it won't be easy to decouple the DB engine from the application process.