[pbs-devel] applied: [PATCH] log: only print error level to syslog/stderr

Thomas Lamprecht t.lamprecht at proxmox.com
Fri Oct 18 19:03:33 CEST 2024


Am 18/10/2024 um 13:11 schrieb Gabriel Goller:
> We only want to print the error level, and not all the levels below
> error to stderr/syslog.
> 
> Signed-off-by: Gabriel Goller <g.goller at proxmox.com>
> ---
> 
> Note: the sign was reversed "<=" would have been correct, because we
> want to print everything that's *less* verbose than Level::ERROR, but

Yeah, this can be easily confusing w.r.t. level and ordered by higher
verbosity or higher impact..

> there is nothing lower than ERROR, so == is better.

probably stems from thinking about syslog, where there is CRIT, ALERT and
EMERG as higher (=worse) level than error.

FWIW, while all those levels are maybe a bit much, I miss at least the NOTICE
one that sits between INFO and WARNING and a higher ERROR one could be useful
for security/data-impact situations.

> 
>  proxmox-log/src/lib.rs | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
>

applied, thanks!




More information about the pbs-devel mailing list