aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndres Freund <andres@anarazel.de>2021-11-19 08:43:12 -0800
committerAndres Freund <andres@anarazel.de>2021-11-19 08:43:12 -0800
commit3b34645678d1a516c148e3e27c26325708e92f6f (patch)
tree4fb30c5710d9225ad9e49578469d3bf0f891153b /src
parent0f0cfb494004befb0f6e89d3129347869420c509 (diff)
downloadpostgresql-3b34645678d1a516c148e3e27c26325708e92f6f.tar.gz
postgresql-3b34645678d1a516c148e3e27c26325708e92f6f.zip
Initialize backend status reporting during bootstrap.
This allows a later commit to reduce the number of branches in performance sensitive functions during normal running, compared to a very minor saving during bootstrapping. Author: Melanie Plageman <melanieplageman@gmail.com> Reviewed-By: Andres Freund <andres@anarazel.de> Discussion: https://postgr.es/m/CAAKRu_Yeg+vh6SHNEo1+=O7e-BPX35cU0XQM=YwQRnkFyv_y+w@mail.gmail.com
Diffstat (limited to 'src')
-rw-r--r--src/backend/utils/init/postinit.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/backend/utils/init/postinit.c b/src/backend/utils/init/postinit.c
index 0c56c38a141..646126edee5 100644
--- a/src/backend/utils/init/postinit.c
+++ b/src/backend/utils/init/postinit.c
@@ -676,8 +676,7 @@ InitPostgres(const char *in_dbname, Oid dboid, const char *username,
EnablePortalManager();
/* Initialize status reporting */
- if (!bootstrap)
- pgstat_beinit();
+ pgstat_beinit();
/*
* Load relcache entries for the shared system catalogs. This must create