On Apr 25 22:19, Myroslav Opyr <[EMAIL PROTECTED]> wrote: > > Subject: Re: [Zope-dev] Running methods on Zope startup. > > Chris McDonough wrote: > > >[snip] > > > There is product ZExternalNews which is working in background from Zope > startup. You can take a look there. There are several Startup issues in > the code.
Yes, this product is doing a similar thing to what I want to do. I note though that it does: app=context._ProductContext__app Ie., it breaks abstraction and accesses the private application context which is available in the product context. Yes, it is possible, but it is (is it) cheating. :-) Is there any reason why the application context in the product context just can't be public in the first place? It would make things easier and doesn't seem that big a deal to change it. At least Zope could provide a public method which gives access to it. I also note that this product does what it needs direct from the product initialize routine. As long as this product doesn't rely in anyway on other products this would be okay, but if it did, it could be a problem as threads created by the product might try to access another product or even part of Zope which hadn't been initialised yet. Anyway, I might just break the encapsulation in the same way for now, will save a lot of work. Thanks for the pointer to this package. -- Graham Dumpleton ([EMAIL PROTECTED]) _______________________________________________ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )