Change ereport level for QueuePartitionConstraintValidation - Mailing list pgsql-hackers

From Sergei Kornilov
Subject Change ereport level for QueuePartitionConstraintValidation
Date
Msg-id 4859321552643736@myt5-02b80404fd9e.qloud-c.yandex.net
Whole thread Raw
Responses Re: Change ereport level for QueuePartitionConstraintValidation
Re: Change ereport level for QueuePartitionConstraintValidation
List pgsql-hackers
Hello

Per discussion started here:
https://www.postgresql.org/message-id/CA%2BTgmoZWSLUjVcc9KBSVvbn%3DU5QRgW1O-MgUX0y5CnLZOA2qyQ%40mail.gmail.com

We have INFO ereport messages in alter table attach partition like this:
> partition constraint for table \"%s\" is implied by existing constraints

Personally I like this message and not want remove it.
But recently my colleague noticed that INFO level is written to stderr by psql. For example, simple command

> psql -c "alter table measurement attach partition measurement_y2006m04 for values from ('2006-04-01') to
('2006-05-01');"

can produce stderr output like error, but this is expected behavior from successful execution.

And INFO level always sent to client regardless of client_min_messages as clearly documented in
src/include/utils/elog.h

So now I am +1 to idea of change error level for this messages. I attach patch to lower such ereport to DEBUG1 level

thanks

PS: possible we can change level to NOTICE but I doubt we will choose this way

regards, Sergei
Attachment

pgsql-hackers by date:

Previous
From: Amit Kapila
Date:
Subject: Re: WIP: Avoid creation of the free space map for small tables
Next
From: Maxence Ahlouche
Date:
Subject: Re: Show a human-readable n_distinct in pg_stats view