[Zope] How to handle ZODB conflict errors

Chris McDonough chrism at plope.com
Wed Sep 29 09:36:52 EDT 2004


On Wed, 2004-09-29 at 08:43, aa bb wrote:
> Dear Zopistas,
> Im using Zope 2.7.0 with installed product ZMS (Content Management
> from Germany) for our Intranet. Data.fs ist about 117MB, mostly
> text objects, some pdf. Machine is P4 2,6GHZ, 512MB, Win2000.
> 
> Sometimes there is considerable delay on delete or save actions,
> usually corresponding to event.log entries such as:
> 
> 2004-09-28T10:34:35 INFO(0) ZODB conflict error
> at /Intranet/content/e14/index_ger.html (8 conflicts since startup)
> or
> 2004-09-28T09:32:33 ERROR(200) Catalog uncatalogObject unsuccessfully
> attempted to uncatalog an object with a uid of /Intranet/content/...

It's certainly possible that conflict errors slow down your site.

> 
> Rebuilding the catalog didnt help as did ZEXPorting the whole to a
> fresh data.fs. Fsrecover.py did not find any problems.
> 
> I unsuccessfully tried to find explanations what the first error
> exactly means. The error_log in the Root directory doesnt give me
> clues.
> 
> Who can tell me what ZODB conflict error exactly means and how it is
> pr oduced? (web documentation seems to assume everybody knows)
> Is the problem necessarily caused by the product?
> Does anybody have a suggestion how to further tackle this?

See the end of the Sessions chapter of the Zope Book for a description
of what conflict errors are. 
http://www.plope.com/Books/2_7Edition/Sessions.stx

Conflict errors are *not* limited to session usage, they are largely a
normal byproduct of the way ZODB handles concurrency for all objects.

If you see very few of them and they are not impacting your application
in a dramatic way, they are nothing to worry about.  OTOH, if they are
impacting your application in a dramatic way, you will likely need to do
some recoding.   If you need to recode, basically to reduce the
potential for conflict errors you'd like to avoid changing the same
object(s) at the same time in two different Zope threads.  What that
means in terms of what lines of code need to change for your particular
application probably can't be known by anyone but its authors.

- C




More information about the Zope mailing list