[ZODB-Dev] POSKeyError in zodb-3.6.0

Alan Runyan runyaga at gmail.com
Fri Nov 10 15:31:15 EST 2006


Hi Chris,

I am no ZODB expert.  But I see a few thins that are wrong with the code.
Others should be able to comment at length:

  - You cant just catch ConflictError and pass

  - I think you can catch a ReadConflictError and *retry* that is ok.

  - But a ConflictError needs to be *retried* manually in your client code.

If you catch a ConflictError you need to abort the transaction.
You should be explicit about *beginning* transactions after ending previous
transaction.

If your using threads.  I believe you need to be a bit more careful.  Does
this code
corrupt ZODB if your *not* using threads?

Instead of using threads try:

  - Write the code to be used in single process

  - Start 3 processes; see if that fails

  - Remove your try/except around ConflictError.  ConflictErrors need to be
handled.
  NOTE: In Zope the framework handled ConflictError's automatically but your
doing
  everything *outside* of Zope.  Which means your code needs to do the
retries.

make sense?

-- 
Alan Runyan
Enfold Systems, Inc.
http://www.enfoldsystems.com/
phone: +1.713.942.2377x111
fax: +1.832.201.8856
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.zope.org/pipermail/zodb-dev/attachments/20061110/abd125ff/attachment.htm


More information about the ZODB-Dev mailing list