Re: elog() patch

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Rod Taylor <rbt(at)zort(dot)ca>, Zeugswetter Andreas SB SD <ZeugswetterA(at)spardat(dot)at>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: elog() patch
Date: 2002-03-04 19:32:25
Message-ID: 200203041932.g24JWP725366@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:
> Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> > I will add a new symbol INFOFORCE which will always be sent to the
> > client no matter what the client_min_messages level.
>
> I was thinking along the same lines, but I hate that name.
> INFOALWAYS maybe?
>
> Also, should it be different from INFO as far as the server log
> goes? Not sure.

In going over the existing INFO messages, I now see that there are
several places that must send messages to the client no matter what
client_min_messages is set to. The areas are EXPLAIN, VACUUM, ANALYZE,
SHOW, and various "unsuported" messages.

So, I am now thinking that INFOALWAYS is not the proper way to handle
these cases. While I saw no value in splitting the current NOTICE
messagees into WARNING and NOTICE (they all seem pretty much the same),
I now see a value in splitting INFO into INFO for "always to client" and
NOTICE which will be things like automatic sequence creation.

So, based on current CVS, NOTICE -> WARNING, and some INFO will be
changed to NOTICE and remaining INFO will always be sent to the client.

If I don't create a new tag, then people who set the client_min_messages
to ERROR will be confused to see INFO messages in some cases and not
others. In the final code, client_min_messages will not have an INFO
level option because INFO will always go to the client.
server_min_messages will have an INFO option.

Comments?

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2002-03-04 19:57:44 Re: [Fwd: [PATCHES] Libpq support for precision and scale]
Previous Message Tom Lane 2002-03-04 19:24:08 Uniqueness of rule, constraint, and trigger names