On Wed, 14 Jun 2000, Loren Stafford wrote:

> I need some advise for designing a flexible system for logging the
> activities of scheduled events.

You could just call Zope's logging system and move it out of the
scope of your product. Have a look at zLOG.py or LOGGING.txt
if you havn't already. Means people can extend their logging system
to their hearts content with no effect on your product.

> But ZScheduler also needs to be ISP independent. That is, you should have
> complete scheduling capabilities for your cohosted Zope applications without
> having to call up the ISP and ask for system configuration changes.
> ZScheduler partially achieves this level of independence, by eliminating the
> need for cron.

This could be achieved with a seperate product. A product that
ties into Zope's logging infrastructure and allows viewing the
log files through the web. All it would have to do is append itself to the
ZLogger.loggers tuple, and the interface is pretty trivial. And of course,
it means that other products can use it without modification (Logger product,
Zope itself etc.) and can be extended as required without having to
submit patches to you for inclusion in ZScheduler.

It would be a good idea if there was a field in the ZEvent that defined
the subsystem used in the zLOG call.

> So, I need a more flexible structure for the logging aspect of ZScheduler.
> While the ZEvent class is subclassable by users, I haven't made the
> Scheduler class instantiable -- there should be only one instance -- so it's
> not subclassable either, and therefore you can't override its logging
> method. Do you see the problem?

> Having little experience with Python and OO applications, I don't know how
> others solve this problem. Can you give me any pointers?

Its not a problem with ZScheduler, it a problem that no one has written
a plug-in logging system that is good enough for what you are trying to
do. The existing zLOG API is fine (well - it could be better), but just
needs someone to write the relevant modules. Hmm... I think I'll
add a section to the Interfaces Wiki...

Stuart Bishop                          Work: [EMAIL PROTECTED]
Senior Systems Alchemist               Play: [EMAIL PROTECTED]
Computer Science, RMIT University

Zope-Dev maillist  -  [EMAIL PROTECTED]
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope )

Reply via email to