Re: zope.component.zcml and global registry

Hanno Schlichting <[email protected]>
Newsgroups gmane.comp.web.zope.devel
Message-ID <[email protected]>
On Wed, Mar 3, 2010 at 11:12 AM, Roger <[email protected]> wrote:
> I like to use getGlobalSiteManager by default because this
> doesn't force a database access and load the local site
> manager if the site is a local site.

The database access only happens if a local site is set into the
corresponding thread local. But such a site is only set up when
traversing over the application root via some events.

At the point in the startup process when ZCML is processed, there's no
traversal events setup that could cause this and nothing should open
the database connection and traverse over it either.

So +1 on using getSiteManager instead of getGlobalSiteManager.

Hanno
_______________________________________________
Zope-Dev maillist  -  [email protected]
https://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope )
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.