From: Stephen Frost <sfrost@snowman.net>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Bruce Momjian <bruce@momjian.us>
Cc: Christoph Berg <myon@debian.org>
Cc: Julien Rouhaud <rjuju123@gmail.com>
Cc: Pavel Stehule <pavel.stehule@gmail.com>
Cc: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
Cc: Magnus Hagander <magnus@hagander.net>
Cc: Fujii Masao <masao.fujii@oss.nttdata.com>
Cc: Michael Paquier <michael@paquier.xyz>
Cc: Andres Freund <andres@anarazel.de>
Cc: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: Peter Eisentraut <peter.eisentraut@enterprisedb.com>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Subject: Re: compute_query_id and pg_stat_statements
Date: Thu, 13 May 2021 14:47:23 -0400
Message-ID: <20210513184723.GH20766@tamriel.snowman.net> (raw)
In-Reply-To: <1579535.1620930549@sss.pgh.pa.us>
References: <20210513015700.fp33q5rfvwl2ahfx@nol>
<20210513030652.GB11075@momjian.us>
<20210513031613.j47baglf6xl3mgbs@nol>
<20210513033332.GF11075@momjian.us>
<20210513040342.fouh7ryglrfgxglu@nol>
<20210513144143.GG11075@momjian.us>
<YJ1kYeKvYBk0cxti@msg.df7cb.de>
<20210513175947.GP11075@momjian.us>
<20210513180706.GG20766@tamriel.snowman.net>
<1579535.1620930549@sss.pgh.pa.us>
Greetings,
* Tom Lane (tgl@sss.pgh.pa.us) wrote:
> Stephen Frost <sfrost@snowman.net> writes:
> > There's a ridiculously simple option here which is: drop the idea that
> > we support an extension redefining the query id and then just make it
> > on/off with the default to be 'on'.
>
> I do not think that defaulting it to 'on' is acceptable unless you can
> show that the added overhead is negligible. IIUC the measurements that
> have been done show the opposite.
Ah, right, it had only been done before when pg_stat_statements was
loaded.. In which case, it seems like we should:
a) go back to that
b) if someone wants an alternative query ID, tell them to add it to
pg_stat_statements and make it configurable *there*
c) Have pg_stat_statements provide another function/view/etc that folks
can use to get a queryid for an ongoing query ..?
d) Maybe come up with a way for extensions, generically, to make a value
available to log_line_prefix? That could be pretty interesting.
Or just accept that this is a bit hokey with the 'auto' approach. I get
Bruce has concerns about it but I'm not convinced that it's actually all
that bad to go with that.
Thanks,
Stephen
Attachments:
signature.asc (application/pgp-signature, 818B) download
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: pgsql-hackers@postgresql.org
Cc: sfrost@snowman.net, tgl@sss.pgh.pa.us, bruce@momjian.us, myon@debian.org, rjuju123@gmail.com, pavel.stehule@gmail.com, horikyota.ntt@gmail.com, magnus@hagander.net, masao.fujii@oss.nttdata.com, michael@paquier.xyz, andres@anarazel.de, alvherre@alvh.no-ip.org, peter.eisentraut@enterprisedb.com, pgsql-hackers@lists.postgresql.org
Subject: Re: compute_query_id and pg_stat_statements
In-Reply-To: <20210513184723.GH20766@tamriel.snowman.net>
* 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