[Zope-dev] API for creating sub-ZODBs

Anthony Pfrunder s341625@student.uq.edu.au
Wed, 20 Oct 1999 08:38:41 +1000 (GMT+1000)


On Tue, 19 Oct 1999, Andrew M. Kuchling wrote:

[snip]
> conn = Zope.App.openExtraZODB( FileStorage, ('/tmp/mystorage.fs',) )
> root = conn.root()
> ... whatever ...
> 
> 	Thoughts?  I'm happy to write such a function, if someone will
> tell me where it should go.

This is cool!  What would be even better is an example of a Folderish
mixin which instead of storing its sub-objects within the main db it
stores it within an external ZODB.  This would be effectively "mounting" a
filesystem within another but still keeping them separate.  Anyone know
how to do this? 

Taking this one-step-further we could enhance Products such that Products
using this mixin will automatically store the contents of stuff within its
Control Panel folder (like ZClasses) in a ZODB within its real world
directory.  This means we can just zip it up to get both external Python
code AND the ZClasses that it uses.  If I knew how the ZODB system works
I'd help out ;).

Cheers,

Anthony Pfrunder