public inbox for pbs-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Lukas Wagner <l.wagner@proxmox.com>
To: Proxmox Backup Server development discussion
	<pbs-devel@lists.proxmox.com>,
	Gabriel Goller <g.goller@proxmox.com>
Subject: Re: [pbs-devel] [PATCH proxmox 1/2] proxmox-log: added tracing infra
Date: Fri, 1 Dec 2023 15:48:21 +0100	[thread overview]
Message-ID: <d767037f-cd45-44f4-af0f-ce005edcb310@proxmox.com> (raw)
In-Reply-To: <48fb398e-d7d4-4e7b-a313-057953b82aca@proxmox.com>



On 12/1/23 10:56, Lukas Wagner wrote:
>> +
>> +        let result = LOGGER.try_with(|logger| {
>> +            log_to_file(&mut logger.borrow_mut(), level, &buf);
>> +        });
>> +        if result.is_err() || *level == Level::ERROR {
>                                                       ^
> Shouldn't this be configurable?
> Or, alternatively would it make sense of drop this comparison and only 
> rely on the env var (e.g. PBS_LOG)?
> 

Argh, misread this line before, sorry. I somehow read this as 'only 
errors should ever got to syslog', but in reality it's 'if task and 
error, it goes to both, syslog and stdout'.

So it's fine as is, IMO.

-- 
- Lukas




  parent reply	other threads:[~2023-12-01 14:48 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-03 11:28 [pbs-devel] [PATCH proxmox-backup 0/2] proxmox-log introduction Gabriel Goller
2023-11-03 11:28 ` [pbs-devel] [PATCH proxmox 1/2] proxmox-log: added tracing infra Gabriel Goller
2023-12-01  9:56   ` Lukas Wagner
2023-12-01 11:13     ` Wolfgang Bumiller
2023-12-01 14:48     ` Lukas Wagner [this message]
2023-11-03 11:28 ` [pbs-devel] [PATCH proxmox-backup 2/2] log: removed task_log! macro and moved to tracing Gabriel Goller
2024-01-22 13:30   ` Lukas Wagner
2023-12-15 13:56 ` [pbs-devel] [PATCH proxmox-backup 0/2] proxmox-log introduction Gabriel Goller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d767037f-cd45-44f4-af0f-ce005edcb310@proxmox.com \
    --to=l.wagner@proxmox.com \
    --cc=g.goller@proxmox.com \
    --cc=pbs-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal