October 10, 2009

Append-only databases

Two years ago, Pat Helland wrote Accountants Don't Use Erasers, which resonated widely in the blogosphere. The central premise, append-only databases, offered a glimpse of the promises of purely functional programming. The idea itself is probably as old as transactional databases, however it has been significantly delayed in practical realization due to the nature of storage hardware.

Append-only filesystems have been around for some time for hard-drives, used mainly for archival storage (the Plan9 Venti filesystem being the most widely known example). Append-only database implementations have been held back by the high seek latency of mechanical drives. This is changing as high-capacity flash drives are becoming available.

Over the summer, Slava Akhmechet (of Weblocks fame), along with Michael Glukhovsky and Leif Walsh, started RethinkDB, a project to build a new append-only MySQL backend. Aside from the performance improvement, RethinkDB manages to solve some glaring MySQL DB management problems: hot backups (without special tools) and fast failure recovery.

The possibilities for flash storage to enable significantly greater database performance were previously noted in several papers (see Lee et alia and Graefe; even the late Jim Gray weighed in on flash drives).

4 comments:

Leslie P. Polzer said...

I'm still not quite sure where the innovation is here.

Berkeley DB and Prevalence databases have been using incremental logging for years now.

There's a BDB backend for MySQL, too.

Vladimir Sedach said...

I don't think there's as much innovation as application going on. A native backend is going to be faster than interfacing with BDB (and more importantly will not have any extra administrative burden), and Slava and co seem to be giving a lot of thought to tuning their implementation to the properties of flash drives specifically.

Leslie P. Polzer said...

Yes indeed, that's how I see it basically.

Daniel Waterworth said...

Hi, I wondered if you'd be interested in aodbm? It's an append only database in the style of dbm. https://sourceforge.net/projects/aodbm/