Mika, David P (Research) wrote:
OK, the opts object really did have everything loaded.  On careful inspection the 
opts.configroot has an attribute "databases" with a list of 
Zope.Startup.datatypes.ZopeDatabase instances.  I can do what I originally set out to do 
which was to open a ZEO.ClientStorage configured from the zope-with-zeo.conf file (the 
ZEO.ClientStorage is now wrapped in a ZEOClient object):

from Zope.Startup import options, handlers
opts = options.ZopeOptions()
opts.configfile='c:\Zope-Instance-Test\etc\zope-with-zeo.conf'
opts.load_schema()
opts.load_configfile()
for db in opts.configroot.databases:
     if is instance(db.config.storage, ZODB.config.ZEOClient):
          db.config.storage.open()

Great, right? Or am I missing some outstanding issue?

cheers,

Chris

--
Simplistix - Content Management, Zope & Python Consulting
           - http://www.simplistix.co.uk
_______________________________________________
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope-dev )

Reply via email to