Re: Clarify VACUUM FULL exclusion in total_vacuum_time docs

2025-06-12 Thread Fujii Masao




On 2025/06/07 0:13, Robert Treat wrote:

On Fri, Jun 6, 2025 at 9:57 AM David G. Johnston
 wrote:

On Friday, June 6, 2025, Fujii Masao  wrote:


Hi,

Since last_vacuum and vacuum_count in pg_stat_all_tables explicitly mention
that they don't include VACUUM FULL ("not counting VACUUM FULL"), I think
we should add the same clarification to the description of total_vacuum_time.
This field also excludes VACUUM FULL, and without this note, users might
mistakenly think the time spent on VACUUM FULL is included. Thought?

 total_vacuum_time double 
precision


-   Total time this table has been manually vacuumed, in milliseconds.
+   Total time this table has been manually vacuumed, in milliseconds
+   (not counting VACUUM FULL).
 (This includes the time spent sleeping due to cost-based delays.)

   



  Makes sense.  Our naming this table rewrite vacuum full does confuse people 
into thinking it is related to vacuum.



+1 for this change,


Thanks both for the review!



but I think we should also update
n_ins_since_vacuum as well, no?


I didn't update n_ins_since_vacuum since it's mainly used by autovacuum rather
than end users, and there haven't been any complaints about the current
description so far. That said, I don't have a strong opinion either way,
so I'm fine with making the change if others think it's worthwhile.

Regards,

--
Fujii Masao
NTT DATA Japan Corporation





wrong statement in the https://www.postgresql.org/docs/current/predefined-roles.html

2025-06-12 Thread PG Doc comments form
The following documentation comment has been logged on the website:

Page: https://www.postgresql.org/docs/14/predefined-roles.html
Description:

Page: https://www.postgresql.org/docs/current/predefined-roles.html
Wrong statement: "Administrators (including roles that have the CREATEROLE
privilege) can GRANT these roles to users and/or other roles in their
environment, providing those users with access to the specified capabilities
and information."
Suggested statement: "SUPERUSER or roles granted with the ADMIN option on
the particular predifined roles can GRANT these roles other roles, providing
those users with access to the specified capabilities and information."
Testcase:
postgres=> create role bob;
CREATE ROLE
postgres=> grant pg_checkpoint to bob;
ERROR:  permission denied to grant role "pg_checkpoint"
DETAIL:  Only roles with the ADMIN option on role "pg_checkpoint" may grant
this role.
postgres=> grant pg_create_subscription to bob;
ERROR:  permission denied to grant role "pg_create_subscription"
DETAIL:  Only roles with the ADMIN option on role "pg_create_subscription"
may grant this role.


Re: wrong statement in the https://www.postgresql.org/docs/current/predefined-roles.html

2025-06-12 Thread Laurenz Albe
On Thu, 2025-06-12 at 08:19 +, PG Doc comments form wrote:
> The following documentation comment has been logged on the website:
> 
> Page: https://www.postgresql.org/docs/14/predefined-roles.html
> Description:
> 
> Page: https://www.postgresql.org/docs/current/predefined-roles.html
> Wrong statement: "Administrators (including roles that have the CREATEROLE
> privilege) can GRANT these roles to users and/or other roles in their
> environment, providing those users with access to the specified capabilities
> and information."
> Suggested statement: "SUPERUSER or roles granted with the ADMIN option on
> the particular predifined roles can GRANT these roles other roles, providing
> those users with access to the specified capabilities and information."
> Testcase:
> postgres=> create role bob;
> CREATE ROLE
> postgres=> grant pg_checkpoint to bob;
> ERROR:  permission denied to grant role "pg_checkpoint"
> DETAIL:  Only roles with the ADMIN option on role "pg_checkpoint" may grant
> this role.
> postgres=> grant pg_create_subscription to bob;
> ERROR:  permission denied to grant role "pg_create_subscription"
> DETAIL:  Only roles with the ADMIN option on role "pg_create_subscription"
> may grant this role.

+1

That looks like a clear oversight.

Yours,
Laurenz Albe