Re: Extension Enhancement: Buffer Invalidation in pg_buffercache
Maxim Orlov <orlovmg@gmail.com>
From: Maxim Orlov <orlovmg@gmail.com>
To: Thomas Munro <thomas.munro@gmail.com>
Cc: vignesh C <vignesh21@gmail.com>,
Palak Chaturvedi <chaturvedipalak1911@gmail.com>, Jim Nasby <jim.nasby@gmail.com>, pgsql-hackers@postgresql.org, Nitin Jadhav <nitinjadhavpostgres@gmail.com>
Date: 2024-03-07T17:20:11Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Add pg_buffercache_evict() function for testing.
- 13453eedd3f6 17.0 landed
Attachments
- v4-0001-Invalidate-Buffer-By-Bufnum.patch (application/octet-stream) patch v4-0001
Quite an interesting patch, in my opinion. I've decided to work on it a bit, did some refactoring (sorry) and add basic tests. Also, I try to take into account as much as possible notes on the patch, mentioned by Cédric Villemain. > and maybe better to go with FlushOneBuffer() ? It's a good idea, but I'm not sure at the moment. I'll try to dig some deeper into it. At least, FlushOneBuffer does not work for a local buffers. So, we have to decide whatever pg_buffercache_invalidate should or should not work for local buffers. For now, I don't see why it should not. Maybe I miss something? -- Best regards, Maxim Orlov.