On Feb 13, 2008, at 1:45 PM, Binger David wrote:

On Feb 13, 2008, at 11:49 AM, Marius Gedminas wrote:

Data-loss bugs are *bad*

Do all of these unfortunate conditions recently described
go away if we don't have references to external "persistent" instances?
Are there benefits of cross-storage references that justify this risk?

Yes, but not unless you understand the semantics.

There's also a problem that we made cross-database references so easy to make that they are made accidentally. We probably need to find a way to make them more explicit, at least optionally. I think where people have gotten into trouble is where they've mounted content trees into other content trees and then moved objects between trees creating cross-database references accidentally. In the short term, people should stop doing that. When we have an API to prevent accidental references, then we can probably support this sort of tree mounting.

In the longer term, multi-database GC is an option. I believe this will be doable.

Also, in the medium term, you can use zc.FileStorage to disable GC during packing. My plan is that this will become a built-in (and cleaner) FileStorage feature in ZODB 3.9.

Note that, IMO, some of the best use cases for multi databases are separating catalog and session data from regular content. Both of these should be pretty safe, although some care would be needed to deal with migrating persistent data from session to content databases.


Jim Fulton
Zope Corporation

For more information about ZODB, see the ZODB Wiki:

ZODB-Dev mailing list  -  ZODB-Dev@zope.org

Reply via email to