[Zope-dev] Zope object oid's

Jonothan Farr jfarr@real.com
Thu, 11 May 2000 16:19:22 -0700


> > oid = object._p_oid
>
> Is this unique for the interpretor session?  Or is this oid constant for
> that object and stroed in the FileStorage?

Yes, yes, and yes.

>
> >
> > I'm not sure how to answer the rest of your questions...
> >
>
> But they're so simple?  Not.

You could implement a storage object that did anything you wanted on the back
end. Keep in mind that when you store an object, you only know essentially the
oid, the timestamp of the transaction, and a pickle of the data you're storing.
You could in theory unpickle the data and use some mechanism for determining
where you want to store it. Problem is when you load an object, you only know
the oid, so you need some other mechanism of determining where to load the
object from based on oid alone. Also, as Jim has mentioned, handling undo and
versions with multiple storages is a 'tricky' problem. ;)

--jfarr