Re: Predefined role pg_maintenance for VACUUM, ANALYZE, CHECKPOINT. - Mailing list pgsql-hackers

From Stephen Frost
Subject Re: Predefined role pg_maintenance for VACUUM, ANALYZE, CHECKPOINT.
Date
Msg-id 20211025174318.GI20998@tamriel.snowman.net
Whole thread Raw
In response to Re: Predefined role pg_maintenance for VACUUM, ANALYZE, CHECKPOINT.  (Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>)
Responses Re: Predefined role pg_maintenance for VACUUM, ANALYZE, CHECKPOINT.  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Greetings,

* Bharath Rupireddy (bharath.rupireddyforpostgres@gmail.com) wrote:
> On Sun, Oct 24, 2021 at 3:15 AM Jeff Davis <pgsql@j-davis.com> wrote:
> > Add new predefined role pg_maintenance, which can issue VACUUM,
> > ANALYZE, CHECKPOINT.
> >
> > Patch attached.
>
> At this point, the idea of having a new role for maintenance work
> looks good. With this patch and Mark Dilger's patch introducing a
> bunch of new predefined roles, one concern is that we might reach to a
> state where we will have patches being proposed for new predefined
> roles for every database activity and the superuser eventually will
> have nothing to do in the database, it just becomes dummy?

Independent of other things, getting to the point where everything can
be done in the database without the need for superuser is absolutely a
good goal to be striving for, not something to be avoiding.

I don't think that makes superuser become 'dummy', but perhaps the
only explicit superuser check we end up needing is "superuser is a
member of all roles".  That would be a very cool end state.

Thanks,

Stephen

Attachment

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: pgsql: Remove unused wait events.
Next
From: "Bossart, Nathan"
Date:
Subject: Re: parallelizing the archiver