Re: please update ps display for recovery checkpoint
Nathan Bossart <bossartn@amazon.com>
From: "Bossart, Nathan" <bossartn@amazon.com>
To: Justin Pryzby <pryzby@telsasoft.com>, Michael Paquier <michael@paquier.xyz>
Cc: "k.jamison@fujitsu.com" <k.jamison@fujitsu.com>, "pgsql-hackers@postgresql.org" <pgsql-hackers@postgresql.org>
Date: 2020-12-03T21:18:07Z
Lists: pgsql-hackers
Attachments
- v4-0001-Add-checkpoint-restartpoint-status-to-ps-display.patch (application/octet-stream) patch v4-0001
Hi,
I like the idea behind this patch. I wrote a new version with a
couple of changes:
1. Instead of using StringInfoData, just use a small buffer along
with snprintf(). This is similar to what the WAL receiver
process does.
2. If the process is the checkpointer, reset the display to "idle"
once the checkpoint or restartpoint is finished. It's easy
enough to discover the backend type, and I think adding a bit
more clarity to the checkpointer display is a nice touch.
3. Instead of "running," use "creating." IMO that's a bit more
accurate.
I considered also checking that update_process_title was enabled, but
I figured that these ps display updates should happen sparsely enough
that it wouldn't make much of an impact.
What do you think?
Nathan
Commits
-
Provide recovery_init_sync_method=syncfs.
- 61752afb2640 14.0 cited
-
Add some checkpoint/restartpoint status to ps display
- df9274adf309 14.0 landed