pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andres Freund <andres@anarazel.de>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: pgstat: Create memory contexts below TopMemoryContext
Date: Sat, 17 Sep 2022 16:09:42 +0000
Message-ID: <E1oZaNx-000lpP-HY@gemulon.postgresql.org> (raw)

pgstat: Create memory contexts below TopMemoryContext

So far they were created below CacheMemoryContext. However, that's not
guaranteed to exist in all situations, leading to memory contexts created as
top-level contexts. There isn't actually a good reason anymore to create them
below CacheMemoryContext, so just creating them below TopMemoryContext seems
the best approach.

Reported-by: Reid Thompson <reid.thompson@crunchydata.com>
Reviewed-by: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
Reviewed-by: Andres Freund <andres@anarazel.de>
Author: "Drouvot, Bertrand" <bdrouvot@amazon.com>
Discussion: https://postgr.es/m/b948b729-42fe-f88c-2f4a-0e65d84c049b@amazon.com
Backpatch: 15-

Branch
------
REL_15_STABLE

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

Modified Files
--------------
src/backend/utils/activity/pgstat.c       | 2 +-
src/backend/utils/activity/pgstat_shmem.c | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)



view thread (2+ messages)

Message-ID: <E1oZaNx-000lpP-HY@gemulon.postgresql.org>
Permalink:  ../E1oZaNx-000lpP-HY@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1oZaNx-000lpP-HY@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: andres@anarazel.de
  Subject: Re: pgsql: pgstat: Create memory contexts below TopMemoryContext
  In-Reply-To: <E1oZaNx-000lpP-HY@gemulon.postgresql.org>
  References: <E1oZaNx-000lpP-HY@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox