Dieter Maurer <dieter <at>> writes:

> Jim Carroll wrote at 2007-6-12 15:57 +0000:
> > ...
> >The code that's running essentially does:
> >
> >   add message to Persistent list in object
> >   get_transaction().commit()
> >   send_email()
> >
> >We are using Zodb 3.3a3, and ZEO 2.3a3.
> >
> >I've read that when a transaction retries, it re-runs 
code on the server side. 
> The ZODB by itself does not rerun anything.
> Zope (its ZPublisher) retries a request up to three times when it
> fails due to a "ConflictError".

I'm not using Zope.  I've got a quixote application that's 
using ZODB and ZEO.

Somehow, the code that adds the message to the persistent 
list is running more than once.  I have read that ZEO will 
re-run python code on a retry, and I think this is what's 
causing the duplicated data.

In my mind, what I need is some sort of assurance that the 
Persistent List is only being appened to once.  For some 
reason the commit() is causing it to be appended more than 
once when there's a conflict error.

How can I isolate my transactions so that a conflict aborts 
the current transaction before re-trying?


For more information about ZODB, see the ZODB Wiki:

ZODB-Dev mailing list  -

Reply via email to