Implements simple mnesia style transactions (#7)