[Zope-dev] improved logging

Romain Slootmaekers romain@zzict.com
Fri, 1 Mar 2002 11:08:23 +0100 (CET)


On Fri, 1 Mar 2002, Chris Withers wrote:

> Romain Slootmaekers wrote:
> > 
> > - Loggers (fi, file logger, db loggers, remote logger, nulllogger,...)
> 
> Zope already has a filer logger, I dunno what you mean by db, remote and null loggers,
> perhaps you can explain?
> 
db= log to database...

remote:what if you want your logs to be put on another machine....

null logger does nothing.

> > - Filters (fi on severity, on subsystem, ...)

> 
> zLOG already provides this. 
> 
> Set STUPID_LOG_SEVERITY to the level you want
> Dunno about subsystem. subsystem is passed to zLOG, so maybe you could do a patch which
> lets subsystem also be controlled by an environment.
> 

> > - LogBus (central accesspoint for the logging framework,
> >   where you can (dynamically) hook your loggers, filters etc...
> 
> This is prettymuch what zLOG is. Take a look at my MailingLogger product for an example.
> It emails log messages with the specified parameters to an address you specify and
> provides an example for rolling your own loggers.

I can write my own stuff. but I need to restart zope if I want to change
the zLOG configuration, or hack it in zope and patch every next release.

if I'm fi trying to figure out what's happening with a possible bug on a
production machine, I'd like fi to temporarily reroute all ERROR logs from
BuggyProduct to file dump.txt so that we don't have to wade through the
log output the 300 other users visiting websites on the server, produce, 
since they are  not using the BuggyProduct.

what if I want to split the logs based on some condition....
I have to change code in Zope, and restart the server ...
that's not the way something like this should be done.

Romain.