Because the datahandler's logging was written in a huge hurry at the last minute, it's going to need a rewrite:
- A custom object is used for logging instead of django's logging facility; it's already running if you
orm.setup()
. - The root logger (
''
) is always hardcoded to talk to a socket; sooner or later we'll need a configuration-based logging config (which again django already provides). - The custom method,
Logger.log
, calls python'slogging.log
, thus losing information asfuncName
will always belog
; the custom extra used instead,caller
, is not reliable, as 3rd party libs don't know to use it (we had this problem with RQ). - In
dhd.serve_log
,jobid
andcaller
had to be taken out due to above issues with RQ. This is becauselogging.basicConfig
sets a configuration for the root (ie global) logger that makes poor assumptions. - It's a datahandler logger, not a gips logger. In the long run, there is no meaningful separation between gips logging and datahandler logging, only differ