[ZODB-Dev] Concurrent transactions
Benji York
benji at zope.com
Fri Jun 1 09:35:59 EDT 2007
Kai Diefenbach wrote:
> Within an adapter I increase a counter (e.g. for every download of an
> file) by doing:
>
> self.counter[0] += 1
>
> self.counter is a PersistentList stored as annotation.
Note that if you use a PersistentList, then the entire list must be
written to the database each time a non-Persistent element changes (or
an item is added or removed from the list). If the list is of any
appreciably size, that will be bad.
--
Benji York
Senior Software Engineer
Zope Corporation
More information about the ZODB-Dev
mailing list