[Zope-dev] Re: ZCatalog and Unique IDs
Evan Simpson
evan@digicool.com
Thu, 25 May 2000 09:28:26 -0400
----- Original Message -----
From: Chris Withers <chrisw@nipltd.com>
> I agree the path from root to an object, with no aquisition, is unique,
> but only per instance of zope...
> I was thinking along the lines of a CORBA POID which, AFAIK, uniquely
> identifies an object on a global scale. Could Zope do something similar?
> Well, here's hoping it makes it into 2.2, I'd be interested to here
> people's views on the CORBA POID idea though...
There are generally two ways (at least) to think about "object identifiers".
You can think of them as unique labels for specific objects, without regard
for location ("Jim Fulton") or as addresses or slots in which objects can be
found ("the CTO"). In this case, an advantage to using the address stance
is that it obeys the Zope pattern of keeping objects in context. A path
always identifies a single object, along with a set of parents. An
OID-derived object could have several paths (or no path at all!), and it
would be difficult to extract any of them, given the bare object.
In the case of Catalogs, much of the time we're probably not interested in
cataloging "whatever lives at this path address"; we want information about
a specific object. Fortunately, the cut/copy/paste and rename
implementations make the path approach workable. As a matter of fact, the
new mountable database code required changing the clipboard operations to
use paths instead of object monikers.
Cheers,
Evan @ digicool & 4-am