Commit 624c803
committed
Raise default async discard threshold to ERROR
There are two basic scenarios where the ring buffer fills up. One is
that an application is simply logging too much and the flushing process
can't keep up, and in this case a discard threshold of WARN or INFO is
probably sufficient to mitigate the problem. However, if flushing has
stopped making progress altogether, e.g. due to a full or failed disk,
then logging calls will block indefinitely. This can result in a
production outage.
This change sets the default discard threshold to ERROR, in order to
better mitigate the scenario where the disk fills up, fails, or is in
the process of failing. With this threshold, logging should only block
at the FATAL level, which would typically mean that the operation is
already failing anyway.1 parent 2f79c39 commit 624c803
File tree
2 files changed
+8
-8
lines changed- log4j-core-test/src/test/java/org/apache/logging/log4j/core/async
- log4j-core/src/main/java/org/apache/logging/log4j/core/async
2 files changed
+8
-8
lines changedLines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
75 | 75 | | |
76 | 76 | | |
77 | 77 | | |
78 | | - | |
| 78 | + | |
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
| |||
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
88 | | - | |
| 88 | + | |
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
| |||
Lines changed: 6 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
| |||
104 | 104 | | |
105 | 105 | | |
106 | 106 | | |
107 | | - | |
108 | | - | |
| 107 | + | |
| 108 | + | |
109 | 109 | | |
110 | 110 | | |
111 | 111 | | |
| |||
0 commit comments