Re: Isn't it better with "autovacuum worker...." instead of "worker took too long to start; canceled" specific to "auto - Mailing list pgsql-hackers

From Bossart, Nathan
Subject Re: Isn't it better with "autovacuum worker...." instead of "worker took too long to start; canceled" specific to "auto
Date
Msg-id EE9AF64E-43A0-4309-BADC-7F4E8D7F4E2E@amazon.com
Whole thread Raw
In response to Isn't it better with "autovacuum worker...." instead of "worker took too long to start; canceled" specific to "auto  (Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>)
List pgsql-hackers
On 10/27/21, 9:29 AM, "Bharath Rupireddy" <bharath.rupireddyforpostgres@gmail.com> wrote:
> Is there a specific reason that we have a generic WARNING "worker took
> too long to start; canceled" for an autovacuum worker? Isn't it better
> with "autovacuum worker took too long to start; canceled"? It is
> confusing to see the generic message in the server logs while
> debugging an issue for a user who doesn't know the internals of
> autovacuum code.

It looks like it has been this way for a while [0].  I don't know if
I've ever seen this message before, and from the comments near it, it
sounds like it is expected to rarely happen.

> To be more informative about the message, how about the following:

My vote is to just change it to

        ereport(WARNING,
                (errmsg("autovacuum worker took too long to start; canceled")));

and call it a day.  If we wanted to add errdetail(), I think we should
make sure it is providing useful context, but I'm not sure what that
might look like.

Nathan

[0] https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=bae0b56


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [PATCH] remove is_member_of_role() from header, add can_set_role()
Next
From: Marcos Pegoraro
Date:
Subject: Modifying TOAST policy will not affect the way existing data is stored ?