[ZODB-Dev] Commit or lock object accross transactions

Christian Reis kiko at async.com.br
Wed Jul 16 15:08:13 EDT 2003


On Wed, Jul 16, 2003 at 06:01:38PM +0100, Toby Dickenson wrote:
> > The problem I see here is that ZODB OIDs are global for *all* objects
> > (of any type) in the database, which might not be what is required here
> > (it certainly wouldn't work for me).
> 
> I dont follow that....?...

Well, I'm guessing the sequences would be defined by a certain type of
object (in my case this is very much so) -- i.e., you want one sequence
for User and another for Message. 

If you keep objects of both types in the same ZODB and use the OID as
your sequence counter, there will (for the obvious reasons) be only one
sequence, which means you might end up with objects with IDs like:

        User 1
     Message 2
        User 4
     Message 3
     Message 5
        User 6

Which may be okay to certain applications, and not to others.

Take care,
--
Christian Reis, Senior Engineer, Async Open Source, Brazil.
http://async.com.br/~kiko/ | [+55 16] 261 2331 | NMFL



More information about the ZODB-Dev mailing list