pg_buffercache tidyup

Started by Mark Kirkwoodover 19 years ago2 messageshackers
Jump to latest
#1Mark Kirkwood
mark.kirkwood@catalyst.net.nz

This is probably terrible timing, but I noticed Tom had done some nice
tidying up on pg_freespacemap to eliminate the clumsy conversion to and
from strings. This patch does a similar thing for pg_buffercache.

I did wonder about not showing buffers that are invalid or not in use
(currently displays all attributes bar the id as NULL). Comments?

Cheers

Mark

Attachments:

pg_buffercache_pages.c-20061022.patchtext/x-patch; name=pg_buffercache_pages.c-20061022.patchDownload+79-78
#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: Mark Kirkwood (#1)
Re: pg_buffercache tidyup

Mark Kirkwood <markir@paradise.net.nz> writes:

This is probably terrible timing, but I noticed Tom had done some nice
tidying up on pg_freespacemap to eliminate the clumsy conversion to and
from strings. This patch does a similar thing for pg_buffercache.

Applied --- it is very late in the cycle, but minor code cleanup of
this sort seems pretty safe.

I did wonder about not showing buffers that are invalid or not in use
(currently displays all attributes bar the id as NULL). Comments?

I think we should leave it as-is. You can easily filter the null rows
if you don't want 'em, while they might be handy for certain sorts of
analysis. Besides, this module has already been out for one release
so we shouldn't change its API on a whim.

regards, tom lane