Browse Source
logging: Caddyfile support for `duration_format` (#4684)
Somehow, this was missed. Oops!
master
Francis Lavoie
3 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
12 additions and
9 deletions
-
modules/logging/encoders.go
|
|
@ -136,6 +136,7 @@ type LogEncoderConfig struct { |
|
|
|
// stacktrace_key <key>
|
|
|
|
// line_ending <char>
|
|
|
|
// time_format <format>
|
|
|
|
// duration_format <format>
|
|
|
|
// level_format <format>
|
|
|
|
// }
|
|
|
|
//
|
|
|
@ -163,6 +164,8 @@ func (lec *LogEncoderConfig) UnmarshalCaddyfile(d *caddyfile.Dispenser) error { |
|
|
|
lec.LineEnding = &arg |
|
|
|
case "time_format": |
|
|
|
lec.TimeFormat = arg |
|
|
|
case "duration_format": |
|
|
|
lec.DurationFormat = arg |
|
|
|
case "level_format": |
|
|
|
lec.LevelFormat = arg |
|
|
|
default: |
|
|
|