From 4f9177db85711834cf16d30fe2195473817e4faf Mon Sep 17 00:00:00 2001 From: Daijiro Fukuda Date: Tue, 24 Jun 2025 17:48:36 +0900 Subject: [PATCH 1/2] system-config: add option forced_stacktrace_level https://github.com/fluent/fluentd/pull/5008 Signed-off-by: Daijiro Fukuda --- deployment/system-config.md | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/deployment/system-config.md b/deployment/system-config.md index 90dda3f6..1ed85648 100644 --- a/deployment/system-config.md +++ b/deployment/system-config.md @@ -259,6 +259,37 @@ NOTE: When enabling log rotation on Windows, log files are separated into `log-s Please see also [Log Rotation Setting](logging.md#log-rotation-setting). +#### `forced_stacktrace_level` + +| type | default | version | +| :--- | :--- | :--- | +| enum | "none" | 1.19.0 | + +Specifies `none` or the log level e.g. `trace`, `debug`, `info`, `warn`, `error`, or `fatal`. + +If you set a log level, log levels of stacktraces are forced to that level. + +Example: + +``` + + log_level info # This is the default. You can omit this. + + forced_stacktrace_level info + + +``` + +This setting results in the following behavior: + +* All stacktraces initially with `info` level (`log_level`) or higher will be forcibly logged with `info` level (`forced_stacktrace_level`). + +Note that stacktraces that do not meet `log_level` are discarded in advance. +Thanks to this, there's no concern that `trace` or `debug`-level stacktraces being excessively output as `info`-level logs. + +You can use this option to exclude all stacktraces from an alerting system if monitoring Fluentd's log files directly. +(You don't need this feature if using [@FLUENT_LOG](logging.md#capture-fluentd-logs) because stacktraces are not routed into the `@FLUENT_LOG` label.) + ### `` section The temporary buffer setting for [Source Only Mode](source-only-mode.md). From 739d65a04f0c6f0fdf72c150a1b2555c814fe9a9 Mon Sep 17 00:00:00 2001 From: Daijiro Fukuda Date: Thu, 26 Jun 2025 09:54:23 +0900 Subject: [PATCH 2/2] Update deployment/system-config.md Signed-off-by: Daijiro Fukuda Co-authored-by: Kentaro Hayashi --- deployment/system-config.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deployment/system-config.md b/deployment/system-config.md index 1ed85648..99b75076 100644 --- a/deployment/system-config.md +++ b/deployment/system-config.md @@ -267,7 +267,7 @@ Please see also [Log Rotation Setting](logging.md#log-rotation-setting). Specifies `none` or the log level e.g. `trace`, `debug`, `info`, `warn`, `error`, or `fatal`. -If you set a log level, log levels of stacktraces are forced to that level. +If you set a log level for `forced_stacktrace_level`, log levels of stacktraces are forced to that level. Example: