pgsql: Add generic_plans and custom_plans fields into pg_prepared_state

From: Fujii Masao <fujii(at)postgresql(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Add generic_plans and custom_plans fields into pg_prepared_state
Date: 2020-07-20 02:56:22
Message-ID: E1jxLyY-00025h-Q0@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Add generic_plans and custom_plans fields into pg_prepared_statements.

There was no easy way to find how many times generic and custom plans
have been executed for a prepared statement. This commit exposes those
numbers of times in pg_prepared_statements view.

Author: Atsushi Torikoshi, Kyotaro Horiguchi
Reviewed-by: Tatsuro Yamada, Masahiro Ikeda, Fujii Masao
Discussion: https://postgr.es/m/CACZ0uYHZ4M=NZpofH6JuPHeX=__5xcDELF8hT8_2T+R55w4RQw@mail.gmail.com

Branch
------
master

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

Modified Files
--------------
doc/src/sgml/catalogs.sgml | 18 ++++++++++++++
src/backend/commands/prepare.c | 15 +++++++++---
src/backend/utils/cache/plancache.c | 17 ++++++++-----
src/include/catalog/pg_proc.dat | 6 ++---
src/include/utils/plancache.h | 3 ++-
src/test/regress/expected/plancache.out | 43 +++++++++++++++++++++++++++++++++
src/test/regress/expected/rules.out | 6 +++--
src/test/regress/sql/plancache.sql | 13 ++++++++++
8 files changed, 105 insertions(+), 16 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Amit Kapila 2020-07-20 03:26:00 pgsql: Immediately WAL-log subtransaction and top-level XID association
Previous Message Amit Kapila 2020-07-20 02:29:14 pgsql: Fix minor typo in nodeIncrementalSort.c.