Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CorrelationIDFromRequest ¶
CorrelationIDFromRequest returns the correlation ID associated with a http.Request
Types ¶
type HTTPLog ¶
type HTTPLog struct { LogOut Logger ServerName string LogName string SkipInfo bool CorrelationHeader string }
HTTPLog is a simple logging middleware that can be added to the net/http server. It supports basic request correlation.
type Logger ¶
type Logger func(string, ...interface{})
Logger is a function that can be used for logging. It has the same signature as log.Printf
func LogfFromRequest ¶
LogfFromRequest returns a function with fmt.Printf signature that will write to the log associated with the request
Click to show internal directories.
Click to hide internal directories.