1
0
mirror of https://github.com/kataras/iris.git synced 2025-12-17 18:07:01 +00:00

recover, accesslog middlewares: give more information to the stored error, accesslog: make use of that information and introduce panic log levels

relative to: https://github.com/kataras/iris/issues/1601#issuecomment-690541789
This commit is contained in:
Gerasimos (Makis) Maropoulos
2020-09-10 21:03:34 +03:00
parent facc94b725
commit 2bb04823b0
4 changed files with 131 additions and 48 deletions

View File

@@ -21,7 +21,12 @@ func main() {
ac.AddOutput(os.Stdout)
ac.TimeFormat = "2006-01-02 15:04:05"
// ac.KeepMultiLineError = false // set to false to print errors as one line.
// Set to false to print errors as one line:
// ac.KeepMultiLineError = false
// Set the "depth" of a panic trace:
ac.PanicLog = accesslog.LogHandler // or LogCallers or LogStack
// Optionally run logging after response has sent:
// ac.Async = true
broker := ac.Broker() // <- IMPORTANT