public inbox for [email protected]  
help / color / mirror / Atom feed
From: Álvaro Herrera <[email protected]>
To: Jim Jones <[email protected]>
Cc: Fujii Masao <[email protected]>
Cc: Fujii Masao <[email protected]>
Cc: Kirill Gavrilov <[email protected]>
Cc: Kirill Reshke <[email protected]>
Cc: Andrey M. Borodin <[email protected]>
Cc: Euler Taveira <[email protected]>
Cc: [email protected]
Subject: Re: Truncate logs by max_log_size
Date: Thu, 5 Feb 2026 11:22:19 +0100
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>

On 2026-Feb-05, Jim Jones wrote:

> On 05/02/2026 03:17, Fujii Masao wrote:
> > At least I'm not for now. So please feel free to work on the patch if
> > you'd like!
> 
> If nobody is planning to work on this, I can take a look at it next week.

That'd be swell.

My only comment at this point is that the proposed GUC name is not
great.  I think it should be something like log_statement_max_length, or
something like that.  Reading just the thread subject, people would
imagine this is about the size of the log file.

Another point is that the current patch does strlen() twice on each
query.  It might be better to do away with need_truncate_query_log() and
have a single routine that both determines whether the truncation is
needed and returns the truncated query if it is.  If it returns NULL
then caller assumes it's not needed.

-- 
Álvaro Herrera               48°01'N 7°57'E  —  https://www.EnterpriseDB.com/






view thread (15+ messages)  latest in thread

reply

Reply instructions:

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

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: Truncate logs by max_log_size
  In-Reply-To: <[email protected]>

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

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox