[Zope] ZODB.POSException.ConflictError (in custommade
product)
Gitte Wange
gitte at mmmanager.org
Sun Oct 26 05:25:45 EST 2003
At 11:03 26-10-2003, Dieter Maurer wrote:
>Gitte Wange wrote at 2003-10-25 13:39 +0200:
> > I have created a small tool for CMF to count how many times a specific
> > object has been viewed.
> > ...
> > Now from time to time we see the following error:
> > ZODB.POSException.ConflictError
>
>
>When you put counters in the ZODB, you should use
>"BTrees.Length" instances. They are small persistent objects with
>conflict resolution (no ZODB write conflicts) and "independence"
>(no ZODB read conflicts).
Arh ...
At this moment I just have a dictionary with URL as key and count as value.
count is a simple integer.
So instead I should save value as an instance of BTrees.Length() ?
Or just I make something else than a dictionary ?
>When you count in an integer object attribute, each increment writes the
>the complete object. This may fast increase your ZODB and
>lead to "ConflictError"s.
Sounds just like what I need to do :-)
Greetings,
Gitte Wange
More information about the Zope
mailing list