public inbox for pdm-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: "Lukas Wagner" <l.wagner@proxmox.com>
To: "Thomas Ellmenreich" <t.ellmenreich@proxmox.com>,
	"Lukas Wagner" <l.wagner@proxmox.com>,
	<pdm-devel@lists.proxmox.com>
Subject: Re: [RFC datacenter-manager/proxmox v2 0/4] log: allow finegrained control logging levels
Date: Fri, 02 Oct 2026 12:59:07 +0200	[thread overview]
Message-ID: <DLUASU9WLUDE.3RJZNHS94TOAZ@proxmox.com> (raw)
In-Reply-To: <DLU9KB2YI8SB.1IPUH3S1ABE2G@proxmox.com>

On Fri Oct 2, 2026 at 12:00 PM CEST, Thomas Ellmenreich wrote:
> On Fri Oct 2, 2026 at 11:44 AM CEST, Lukas Wagner wrote:
>> On Fri Oct 2, 2026 at 11:34 AM CEST, Thomas Ellmenreich wrote:
>>> Thank you very much for your review. I will address the changes in the
>>> next version. I have one question below:
>>>
>>> On Fri Oct 2, 2026 at 10:10 AM CEST, Lukas Wagner wrote:
>>>
>>> [snip]
>>>
>>>>> - Initially, I found case 3. of the different logging cases quite confusing and
>>>>>   would have thought that our 'default_log_level' should apply as default in
>>>>>   that case. Unfortunately, when setting 'default_log_level' and then applying
>>>>>   the EnvFilter string, tracing applies the modules as expected, but then also
>>>>>   overrides the default as '', which means off.
>>>>
>>>> Indeed a bit confusing, but since this is (mostly) a
>>>> developer/supporter feature, as long at this behavior is documented
>>>> somewhere, it should be manageable.
>>>
>>> Since you mentioned it, should I add some documentation somewhere
>>> explaining how to use these env filters? If so, where would be the best
>>> place for it?
>>
>> Since as I mentioned this is (mostly) a developer-feature, I think adding
>> a small section about it in the 'dev-docs' (this is a folder in the PDM
>> repo) would be a good start.
>>
>> It of course still could also make sense to mention in the user-facing
>> product documentation, but as we have briefly discussed off-list, module
>> paths are inherently unstable, so it's somewhat pointless to provide
>> examples there. Familiarity with the code structure is required to
>> properly use this feature.
>
> Yes, I totally understand. I was also thinking of adding it to the developer
> focus documentation for the reasons you mentioned.
>
>> So for now, I'd just add it as developer documentation.
>>
>> I've noticed that PDM and PBS use different conventions for the
>> environment variable, in PDM we use PROXMOX_DEBUG, while in PBS we use
>> PBS_LOG -- maybe that's also something where we should find a common
>> style to use. Just thinking out aloud here, no need to touch this as
>> part of this series, of course.
>
> I was actually wondering about this when creating the series. In my mind, all
> log level variables should end with '_LOG', but we can't really replace
> 'PROXMOX_DEBUG' since it is already in use. Could we also support a 'PDM_LOG'
> variable alongside it, and then first deprecate and later remove the old one?
> (Not for this series, but just as a thought)


I grepped the user-facing documentation and did a quick google search,
found no examples of the PROXMOX_DEBUG variable being described, so I
*think* we might get away with just changing the variable.

The approach you described is of course the 'cleaner' approach, but I
guess that would require API changes in proxmox-log, not sure if that is
worth it.

What we would do is check on startup if the old variable is set, and if
that is the case, we show a warning that guides the user to use the new
one. A user caring about detailed logging would then hopefully notice
this since they check the logs anyway.

Probably best to get one or two other opinions on this before we change
this. It's not super urgent anyway, this is also something we could do
at the next major version (PDM 1.x -> PDM 2.x), then it would simply be
a breaking change that is mentioned in the release notes, as usual.

>
>>>
>>> [snip]





      reply	other threads:[~2026-10-02 10:59 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-23 11:57 [RFC datacenter-manager/proxmox v2 0/4] log: allow finegrained control logging levels Thomas Ellmenreich
2026-09-23 11:57 ` [PATCH proxmox v2 1/4] log: replace per layer filtering by one global filter Thomas Ellmenreich
2026-10-02  8:10   ` Lukas Wagner
2026-09-23 11:58 ` [PATCH proxmox v2 2/4] fix #6081: log: replace simple level filter with env filter Thomas Ellmenreich
2026-10-02  8:10   ` Lukas Wagner
2026-09-23 11:58 ` [PATCH proxmox v2 3/4] log: add tests to the logger Thomas Ellmenreich
2026-10-02  8:10   ` Lukas Wagner
2026-09-23 11:58 ` [PATCH datacenter-manager v2 4/4] api: set REST server debug level based on actual log level Thomas Ellmenreich
2026-10-02  8:10 ` [RFC datacenter-manager/proxmox v2 0/4] log: allow finegrained control logging levels Lukas Wagner
2026-10-02  9:34   ` Thomas Ellmenreich
2026-10-02  9:44     ` Lukas Wagner
2026-10-02 10:00       ` Thomas Ellmenreich
2026-10-02 10:59         ` Lukas Wagner [this message]

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=DLUASU9WLUDE.3RJZNHS94TOAZ@proxmox.com \
    --to=l.wagner@proxmox.com \
    --cc=pdm-devel@lists.proxmox.com \
    --cc=t.ellmenreich@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