On Sun, 2021-10-24 at 21:32 +0000, Bossart, Nathan wrote:
> My initial reaction was that members of pg_maintenance should be able
> to do all of these things (VACUUM, ANALYZE, CLUSTER, REINDEX, and
> CHECKPOINT).
What about REFRESH MATERIALIZED VIEW? That seems more specific to a
workload, but it's hard to draw a clear line between that and CLUSTER.
> Maybe one
> option is to have two separate roles, one for commands that require
> lower lock levels (i.e., ANALYZE and VACUUM without TRUNCATE and
> FULL), and another for all of the maintenance commands.
My main motivation is CHECKPOINT and database-wide VACUUM and ANALYZE.
I'm fine extending it if others think it would be worthwhile, but it
goes beyond my use case.
Regards,
Jeff Davis