[ZODB-Dev] InvalidObjectReference and mount
Jeremy Hylton
jeremy@alum.mit.edu
Fri, 3 Jan 2003 11:19:05 -0500
Sidnei asked me a question this morning about InvalidObjectReference.
I only vaguely understand the issues, so I can't answer.
The question, in essence, is: If I get an InvalidObjectReference
exception, what have I done wrong?
I understand the details of how InvalidObjectReference is raised, but
not how it fits into the mount architecture. It appears that if a
persistent object with _p_jar == A has a reference to persistent
object with _p_jar == B, where A != B, then you get an IOR error.
I think this makes sense, because a reference in the database just
stores an oid (and some class metadata). This oid is local to a
database, but if the jars aren't equal, there's no way to know if the
oid is from a foreign database. Is that right?
If so, what does mounting actually do? I'm imagining that a mount
point is a special object that allows traversal from one database to
another, but doesn't actually allow an object in the database
containing the mount to have a direct reference to objects in the
mounted database.
Jeremy