Is there a way to log processed events?
bradydean opened this issue · 3 comments
I've been looking around I don't see an option for it, or any indication it exists, but I'm looking for a way to log each event as they are processed. Just simple stuff like the date, topic, etc. It seems I would have to write this code by hand in each agent at the moment.
Faust has a lot of logging functionality built into it, as does mode-streaming
since it does some magic to the logging handlers. You may want to check out https://faust-streaming.github.io/faust/userguide/sensors.html.
Thanks, I ended up subclassing Monitor and adding a log where necessary.
@wbarnha Do you have any docs I could reference on the mode logging magic? I'm trying to get a logger/handler for stdout but everything goes to stderr.
logging_config={
"version": 1,
"merge": True,
"loggers": {
"my.package": {
"level": "INFO",
"handlers": ["accesslog"]
},
},
"handlers": {
"accesslog": {
"class": "logging.StreamHandler",
"level": "INFO",
"stream": sys.stdout,
}
}
}