I am using the Amnesia wrapper around mnesia. Now I wanted to write a transaction that simply aborts on a given condition.
Normally you do transactions like this:
< reads and writes >
It seems like there is no abort function in this library. And calling :mnesia.abort/1 will kill the whole DB process with an uncaught exception… So does creating a match error.
I thought inside a :mnesia transaction an error/exception just leads to an abort… but it seems Amnesia doesn’t work the same.
Any ideas? There’s really little on the net regarding this library.