[Zope-dev] Unique ID generation with ZODB.
Andreas Jung
andreas at andreas-jung.com
Mon Apr 5 08:30:23 EDT 2004
The simplest solution is to keep the counter as file in the filesystem.
Access to the file
must be synchronized through a lock object (-> Python docs). Just a few
lines of Python
code.
-aj
--On Montag, 5. April 2004 14:18 Uhr +0200 Syver Enstad <syver at inout.no>
wrote:
>
> How does one implement a unique id generator in ZODB. The id's should
> be strictyl ascending and be a an int. Would opening a temporary
> connection increment a persistent counter and commit do the trick?
>
>
>
> _______________________________________________
> Zope-Dev maillist - Zope-Dev at zope.org
> http://mail.zope.org/mailman/listinfo/zope-dev
> ** No cross posts or HTML encoding! **
> (Related lists -
> http://mail.zope.org/mailman/listinfo/zope-announce
> http://mail.zope.org/mailman/listinfo/zope )
More information about the Zope-Dev
mailing list