Re: Latch for the WAL writer - further reducing idle wake-ups.

Simon Riggs <simon@2ndquadrant.com>

From: Simon Riggs <simon@2ndQuadrant.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Peter Geoghegan <peter@2ndquadrant.com>, Magnus Hagander <magnus@hagander.net>, Robert Haas <robertmhaas@gmail.com>, PG Hackers <pgsql-hackers@postgresql.org>
Date: 2012-05-07T18:51:04Z
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 →
  1. Make bgwriter sleep longer when it has no work to do, to save electricity.

On 7 May 2012 19:44, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Simon Riggs <simon@2ndQuadrant.com> writes:
>> On 7 May 2012 18:09, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>>> I also notice that the separate-checkpointer patch failed to rename
>>> assorted things like BgWriterCommLock, BgWriterRequest,
>>> BgWriterShmemStruct, which are all 100% inappropriately named now.
>>> And it still contains various obsolete comments referring to itself
>>> as the background writer.  Will see about cleaning that up.
>
>> For want of a better name, keeping them the same seemed best.
>
> I was just thinking s/BgWriter/Checkpointer/, do you think that's too
> long?

CheckpointerCommLock
CheckpointerShmemStruct
work OK

CheckpointerRequest
sounds a little vague, but can be tweaked

It also leaves the situation that we have a catalog view called
pg_stat_bgwriter that would be accessing "checkpointer" things. That's
really the thorny one that I wasn't sure how to handle. Good example
of why we shouldn't expose internals too much.

-- 
 Simon Riggs                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services