Commit 31eff16
committed
logging: ForceLog option to log all messages
Once a zap logger is created, its minimum log level is set in its core.
It is possible to log at this level or at a higher level, for example,
when setting info, one can log at info or error. However, it is not
possible to decrease the level of the logger.
This can be useful when the user has configured a high default level,
but some messages still need to be logged without giving them a
ridiculously high level, e.g., a start log entry with a version string
as an error log entry.1 parent c2f0318 commit 31eff16
1 file changed
+11
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
117 | 117 | | |
118 | 118 | | |
119 | 119 | | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
0 commit comments