pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Bruce Momjian <bruce@momjian.us>
To: Alicja Kucharczyk <zaledwie10minut@gmail.com>
Cc: Ron <ronljohnsonjr@gmail.com>
Cc: pgsql-general@lists.postgresql.org
Subject: Re: Use case for enabling log_duration other than benchmarking
Date: Tue, 17 Jan 2023 16:26:02 -0500
Message-ID: <Y8cSagpVTiNaEicv@momjian.us> (raw)
In-Reply-To: <CAM=sWa4x+_yzXEY_g-p+rXg3LQnrrSfmiu4OTmpsx_KgL=pkGA@mail.gmail.com>
References: <CAM=sWa5kArsJrPXOMVDx9137YjJGsaUXF1c1aBt-Lqk2uXt-+Q@mail.gmail.com>
	<ea71e4b5-bb1c-00ea-4376-b87e3327de58@gmail.com>
	<CAM=sWa4x+_yzXEY_g-p+rXg3LQnrrSfmiu4OTmpsx_KgL=pkGA@mail.gmail.com>

On Tue, Jan 10, 2023 at 04:57:11PM +0100, Alicja Kucharczyk wrote:
> thank you Ron.
> My question is a bit more practical - Does anyone really find it useful? 
> What value brings the info that 20% of my query are under 1ms and 10% over 1
> minute - If just checked once and then turned off - I can understand to have
> more visibility into the overall characteristics. But let say someone have it
> enabled on a production system all the time - what could be the reason for
> that?

I think the big value is that enabling log_statement and log_duration
prints the statement text when it _starts, while enabling only
log_min_duration_statement prints the statement and duration when it
_ends_.

-- 
  Bruce Momjian  <bruce@momjian.us>        https://momjian.us
  EDB                                      https://enterprisedb.com

Embrace your flaws.  They make you human, rather than perfect,
which you will never be.





view thread (6+ messages)

Message-ID: <Y8cSagpVTiNaEicv@momjian.us>
Permalink:  ../Y8cSagpVTiNaEicv@momjian.us/
Also on:    postgresql.org/message-id/Y8cSagpVTiNaEicv@momjian.us

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: bruce@momjian.us, zaledwie10minut@gmail.com, ronljohnsonjr@gmail.com
  Subject: Re: Use case for enabling log_duration other than benchmarking
  In-Reply-To: <Y8cSagpVTiNaEicv@momjian.us>
  References: <CAM=sWa5kArsJrPXOMVDx9137YjJGsaUXF1c1aBt-Lqk2uXt-+Q@mail.gmail.com> <ea71e4b5-bb1c-00ea-4376-b87e3327de58@gmail.com> <CAM=sWa4x+_yzXEY_g-p+rXg3LQnrrSfmiu4OTmpsx_KgL=pkGA@mail.gmail.com> <Y8cSagpVTiNaEicv@momjian.us>

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

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