pgsql: Allow compute_query_id to be set to 'auto' and make it default

From: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Allow compute_query_id to be set to 'auto' and make it default
Date: 2021-05-15 18:14:18
Message-ID: E1lhynq-0000O2-8q@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Allow compute_query_id to be set to 'auto' and make it default

Allowing only on/off meant that all either all existing configuration
guides would become obsolete if we disabled it by default, or that we
would have to accept a performance loss in the default config if we
enabled it by default. By allowing 'auto' as a middle ground, the
performance cost is only paid by those who enable pg_stat_statements and
similar modules.

I only edited the release notes to comment-out a paragraph that is now
factually wrong; further edits are probably needed to describe the
related change in more detail.

Author: Julien Rouhaud <rjuju123(at)gmail(dot)com>
Reviewed-by: Justin Pryzby <pryzby(at)telsasoft(dot)com>
Discussion: https://postgr.es/m/20210513002623.eugftm4nk2lvvks3@nol

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/cafde58b337e007cb6a719f5ab4dd6459d932a39

Modified Files
--------------
contrib/pg_stat_statements/pg_stat_statements.c | 6 ++++
contrib/pg_stat_statements/pg_stat_statements.conf | 1 -
doc/src/sgml/config.sgml | 9 +++--
doc/src/sgml/pgstatstatements.sgml | 14 +++-----
doc/src/sgml/release-14.sgml | 2 ++
src/backend/commands/explain.c | 2 +-
src/backend/parser/analyze.c | 4 +--
src/backend/postmaster/postmaster.c | 3 ++
src/backend/tcop/postgres.c | 2 +-
src/backend/utils/misc/guc.c | 38 ++++++++++++++++------
src/backend/utils/misc/postgresql.conf.sample | 2 +-
src/backend/utils/misc/queryjumble.c | 21 ++++++++++++
src/include/utils/guc.h | 1 -
src/include/utils/queryjumble.h | 33 +++++++++++++++++--
14 files changed, 108 insertions(+), 30 deletions(-)

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2021-05-15 18:43:31 Re: pgsql: Allow compute_query_id to be set to 'auto' and make it default
Previous Message Tom Lane 2021-05-15 16:21:29 pgsql: Be more careful about barriers when releasing BackgroundWorkerSl