support for nested transactions
Craig Brozefsky <craig-bqtBzms/kfRWk0Htik3J/[email protected]> Sat, 15 Apr 2006 09:21:43 -0500
| Newsgroups | gmane.lisp.clsql.devel |
|---|---|
| Message-ID | <[email protected]> |
I've been replacing USQL with CLSQL in the project which originally
spawned USQL years ago. In the process I needed support for "nested"
transactions. Meaning, I needed to be able to have code like this:
(with-transaction ...
(with-transaction ...
(with-transaction ...
Commit and Abort properly. For me, properly means that if any of the
bodies throws an error, the transaction is aborted. And that when the
last body is finished, it commits it and runs any commit/abort hooks
for all the bodies. The hooks are not fired until the last
transaction goes out of scope.
Using mark-database-commited does not work with this arrangement, and
I had to make some other minor patches to the start/commit/abort
transaction methods.
I'll package the diff up, but I'm wondering how others are using CLSQL
transactions. What kinda patch you want? Should I just set up a cvs
working copy?
I'm also going to be doing some other worth with CLSQL related to
inheritance of view-classes and supporting several different ways of
laying them out in the db tables.
--
Sincerely, Craig Brozefsky <craig-bqtBzms/kfRWk0Htik3J/[email protected]>
"Sí Se Puede / It Can Be Done!" -- César Chávez