From 39cb334d833a65e4ccc8436c76aa6e76b59e44b1 Mon Sep 17 00:00:00 2001 From: Justin Pryzby Date: Thu, 8 Apr 2021 00:11:53 -0500 Subject: [PATCH 6/7] lock: Make use of in-core query id added by commit 5fd9dfa5f5 4f0b0966c866ae9f0e15d7cc73ccf7ce4e1af84b --- src/backend/utils/activity/backend_status.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/backend/utils/activity/backend_status.c b/src/backend/utils/activity/backend_status.c index 6110113e56..5c1b2c25ed 100644 --- a/src/backend/utils/activity/backend_status.c +++ b/src/backend/utils/activity/backend_status.c @@ -1032,10 +1032,10 @@ pgstat_get_my_queryid(void) if (!MyBEEntry) return 0; - /* There's no need for a look around pgstat_begin_read_activity / + /* There's no need for a lock around pgstat_begin_read_activity / * pgstat_end_read_activity here as it's only called from * pg_stat_get_activity which is already protected, or from the same - * backend which mean that there won't be concurrent write. + * backend which means that there won't be concurrent writes. */ return MyBEEntry->st_queryid; } -- 2.17.0