Re: Summary function for pg_buffercache
От | Zhang Mingli |
---|---|
Тема | Re: Summary function for pg_buffercache |
Дата | |
Msg-id | 885e438b-9d10-4d1f-a3ad-dc7beabfa679@Spark обсуждение исходный текст |
Ответ на | Re: Summary function for pg_buffercache (Melih Mutlu <m.melihmutlu@gmail.com>) |
Ответы |
Re: Summary function for pg_buffercache
Re: Summary function for pg_buffercache |
Список | 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.
```
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:
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 по дате отправления: