pgstat: introduce pgstat_relation_should_count().
authorAndres Freund <andres@anarazel.de>
Mon, 21 Mar 2022 02:12:09 +0000 (19:12 -0700)
committerAndres Freund <andres@anarazel.de>
Mon, 21 Mar 2022 02:12:09 +0000 (19:12 -0700)
commit8363102009d8ee64255ad4948183f9d159eb8f4b
tree03049da609c2c963b59991e7a6f518da4c9c2b0e
parent2d655a08d532feed356222a8b1e427561dc7a883
pgstat: introduce pgstat_relation_should_count().

A later commit will make the check more complicated than the
current (rel)->pgstat_info != NULL. It also just seems nicer to have a central
copy of the logic, even while still simple.

Author: Andres Freund <andres@anarazel.de>
Discussion: https://postgr.es/m/20220303021600.hs34ghqcw6zcokdh@alap3.anarazel.de
src/backend/catalog/index.c
src/backend/postmaster/pgstat.c
src/include/pgstat.h