summaryrefslogtreecommitdiff
path: root/meson_options.txt
diff options
context:
space:
mode:
authorEd Tanous <ed@tanous.net>2024-02-17 00:08:34 +0300
committerEd Tanous <ed@tanous.net>2024-03-21 00:39:32 +0300
commit4d1db045ef30d0b717220d2ef61530c2b1fb0bb1 (patch)
treedcb7822e70b7c14c9047af758493c085999e8105 /meson_options.txt
parentb6164cbec4dd7f5c4e6e7667b203874e11cd8b3c (diff)
downloadbmcweb-4d1db045ef30d0b717220d2ef61530c2b1fb0bb1.tar.xz
Change logging to default to Error/Critical
Historically, logging has been disabled in bmcweb for two reasons. First, the crow logging handler used iostreams, which can bloat binary sizes if there are lots of logging call sites. Second, the amount of logging and the levels at which is was performed were not very carefully selected by either crow, or the follow on bmcweb. A number of log calls logged at Error or Critical level that are fully expected to occur in a normally operating service. The first was corrected with commit 62598e3, which replaced the iostreams logger with c++20 compliant std::format. The second was corrected by Gunnar, documenting when and where to log different levels in commit 0e88cb3, and a series of commits after making the levels usage more consistent. With those two changes in place and showing the appearance of being functional, this patchset is recommending that we change the default error level to log Critical and Error levels by default. A number of organizations have already made this change to their local systems [1], opting for varying levels. Given that we're now internally consistent, this is going to request that we modify those systems to accept defaults once again. There are two negatives to this being the default. 1. We take a 2.7% increase (about 27KB) in binary size. Given the last couple years of reductions in the default binary size, this shouldn't cause any platforms to go over their flash limit, and we're still well within the documented size targets. 2. Error paths now log, which slows down the result, and increases the potential that a DOS attack or test will slow down real results. This concern is hypothetical at best, but we will have to watch for repeated patterns emerging and evaluate if this is a potential problem. Please comment. [1] https://github.com/search?q=repo%3Aopenbmc%2Fopenbmc%20bmcweb-logging&type=code Change-Id: Ib32654c3bcbcbee567f3bd7abd003411dd9e489a Signed-off-by: Ed Tanous <ed@tanous.net>
Diffstat (limited to 'meson_options.txt')
-rw-r--r--meson_options.txt2
1 files changed, 1 insertions, 1 deletions
diff --git a/meson_options.txt b/meson_options.txt
index fe5aa00783..0e7df3acbc 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -140,7 +140,7 @@ option(
'bmcweb-logging',
type: 'combo',
choices : [ 'disabled', 'enabled', 'debug', 'info', 'warning', 'error', 'critical' ],
- value: 'disabled',
+ value: 'error',
description: '''Enable output the extended logging level.
- disabled: disable bmcweb log traces.
- enabled: treated as 'debug'