OPSI.web2.log module¶
Logging tools. This is still in flux (even moreso than the rest of web2).
-
class
OPSI.web2.log.
BaseCommonAccessLoggingObserver
¶ Bases:
object
An abstract Twisted-based logger for creating access logs.
Derived implementations of this class must implement the
logMessage(message)
method, which will send the message to an actual log/file or stream.-
computeTimezoneForLog
(tz)¶
-
emit
(eventDict)¶
-
logDateString
(when)¶
-
logFormat
= '%s - %s [%s] "%s" %s %d "%s" "%s"'¶
-
logMessage
(message)¶
-
start
()¶ Start observing log events.
-
stop
()¶ Stop observing log events.
-
tzForLog
= None¶
-
tzForLogAlt
= None¶
-
-
class
OPSI.web2.log.
DefaultCommonAccessLoggingObserver
¶ Bases:
OPSI.web2.log.BaseCommonAccessLoggingObserver
Log requests to default twisted logfile.
-
logMessage
(message)¶
-
-
class
OPSI.web2.log.
FileAccessLoggingObserver
(logpath)¶ Bases:
OPSI.web2.log.BaseCommonAccessLoggingObserver
I log requests to a single logfile
-
logMessage
(message)¶
-
start
()¶
-
stop
()¶
-
-
class
OPSI.web2.log.
LogInfo
¶ Bases:
object
-
bytesSent
= None¶
-
responseCompleted
= None¶
-
secondsTaken
= None¶
-
startTime
= None¶
-
-
class
OPSI.web2.log.
LogWrapperResource
(resource)¶ Bases:
OPSI.web2.resource.WrapperResource
-
hook
(request)¶
-
-
OPSI.web2.log.
logFilter
(request, response, startTime=None)¶