(o Options)
| 61 | } |
| 62 | |
| 63 | func initApplicationLog(o Options) { |
| 64 | if o.ApplicationLogJSONEnabled { |
| 65 | if o.ApplicationLogJsonFormatter != nil { |
| 66 | logrus.SetFormatter(o.ApplicationLogJsonFormatter) |
| 67 | } else { |
| 68 | logrus.SetFormatter(&logrus.JSONFormatter{}) |
| 69 | } |
| 70 | } else if o.ApplicationLogPrefix != "" { |
| 71 | logrus.SetFormatter(&prefixFormatter{o.ApplicationLogPrefix, logrus.StandardLogger().Formatter}) |
| 72 | } |
| 73 | |
| 74 | if o.ApplicationLogOutput != nil { |
| 75 | logrus.SetOutput(o.ApplicationLogOutput) |
| 76 | } |
| 77 | } |
| 78 | |
| 79 | func createAccessLog(o Options) *AccessLogger { |
| 80 | l := logrus.New() |
no test coverage detected
searching dependent graphs…