A common mistake for new users is to treat the database root
object as a big collection. There are 2 problems with this:
1. The current root object implementation isn't scalable.
2. Making the root object an application collection reduces flexibility
because the database can effectively only have a single collection.
I think this is a problem that needs to be solved. Some possible
A. Change ZODB so that new databases have BTrees as root objects.
This has the advantage that BTrees are scalable. It has a number
of down sides:
- BTrees should only be used when keys are known to have a stable
ordering. If we had a scalable hash data structure, that would
- This encourages mistake 2 above.
B. Change ZODB so that the root object is a variant of persistent
mapping that either refuses to store more than a small number of
objects, or at least issues a warning when more than a small
number of objects is stored.
I think I prefer B. What do other folks think? Any other ideas?
For more information about ZODB, see the ZODB Wiki:
ZODB-Dev mailing list - ZODB-Dev@zope.org