[ZODB-Dev] committing only one database

Christian Reis kiko@async.com.br
Wed, 11 Dec 2002 19:00:19 -0200


On Wed, Dec 11, 2002 at 12:39:57PM -0800, David McCusker wrote:
> I've noticed folks mention connection based transactions.  Is there any
> short overview of this, or sample code?   Or is reading patches the
> only way to learn how to use such features?

Shane's message from about a week back is a good guide to get yourself
set up (there's one call you need to make, setLocalTransaction()). Then
it's a matter of changing your code to use specific connections for the
parts of your application that you want transactions isolated to and
moving away from get_connection().

> We're trying to come up with repository based interfaces.  Existing
> code at OSAF already incorrectly gives the impression that stores commit
> separately when get_transaction().commit() actually commits them all.

Ours did too, till I decided to audit and fix it.

Take care,
--
Christian Reis, Senior Engineer, Async Open Source, Brazil.
http://async.com.br/~kiko/ | [+55 16] 261 2331 | NMFL