On 10/27/21, 9:29 AM, "Bharath Rupireddy" 
<bharath.rupireddyforpostg...@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

Reply via email to