[Zope] ConflictError (ID-Counter for all Documents)

Thomas Guettler zopestoller@thomas-guettler.de
Thu, 24 Jan 2002 11:59:18 +0100


I am developing a simple Document Management System with a python 
product. All documents are in one
folder. If a new document gets created I do the following:

        root.last_id=root.last_id+1

If  I stress test this with httperf I get ConflictErrors.

I searched and found two solutions:

Catch the Exception, and retry it.

Use PCounter from ZODB/test/ConflictResolution.py

Are there other, better solutions?
Which one is better?

 thomas