Hi,
I'm interested in capturing all the inserts/updates and deletes - Especially I want the auth_user performing these operations and the timestamp(s) for the operations.
This will be useful in production setup to figure out who modified/deleted specific record in case things go wrong.
(When I was using pylons+sqlalchemy in one of my earlier projects, I found this functionality useful, and all I had to do was modify logging.conf)
I played around with logging - copied logging.example.conf to logging.conf, then added following lines :
[loggers]
keys=root,rocket,markdown,web2py,dal,rewrite,cron,app,welcome
[logger_dal]
level=DEBUG
handlers=consoleHandler,rotatingFileHandler
qualname=web2py.dal
propagate=0
Then I restarted web2py. But I still don't see any DB transactions in the log.
Further looking into gluon/dal.py - I realized that insert/update/delete() do NOT have logger.debug statements - It is likely that is why I don't see anything in the log/web2py.log
Any sugestions how I get the functionality ?
Thanks,
-Mandar