Re: Summary function for pg_buffercache - Mailing list pgsql-hackers

From Zhang Mingli
Subject Re: Summary function for pg_buffercache
Date
Msg-id 885e438b-9d10-4d1f-a3ad-dc7beabfa679@Spark
Whole thread Raw
In response to Re: Summary function for pg_buffercache  (Melih Mutlu <m.melihmutlu@gmail.com>)
Responses Re: Summary function for pg_buffercache
Re: Summary function for pg_buffercache
List pgsql-hackers
Hi,

Correct me if I’m wrong.

The doc says we don’t take lock during pg_buffercache_summary, but I see locks in the v8 patch, Isn’t it?

```
Similar to <function>pg_buffercache_pages</function> function
 <function>pg_buffercache_summary</function> doesn't take buffer manager
 locks, thus the result is not consistent across all buffers. This is
 intentional. The purpose of this function is to provide a general idea about
 the state of shared buffers as fast as possible. Additionally,
 <function>pg_buffercache_summary</function> allocates much less memory.

```




Regards,
Zhang Mingli
On Sep 20, 2022, 20:10 +0800, Melih Mutlu <m.melihmutlu@gmail.com>, wrote:
Hi,

Seems like cfbot tests are passing now:

Best,
Melih

Melih Mutlu <m.melihmutlu@gmail.com>, 20 Eyl 2022 Sal, 14:00 tarihinde şunu yazdı:
Aleksander Alekseev <aleksander@timescale.com>, 20 Eyl 2022 Sal, 13:57 tarihinde şunu yazdı:
There was a missing empty line in pg_buffercache.out which made the
tests fail. Here is a corrected v8 patch.

I was just sending a corrected patch without the missing line. 

Thanks a lot for all these reviews and the corrected patch.

Best,
Melih  

pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: Add SPLIT PARTITION/MERGE PARTITIONS commands
Next
From: Aleksander Alekseev
Date:
Subject: Re: Summary function for pg_buffercache