Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Added to TODO:
> * Change DEBUG tag used in server logs
> Seems it should say NOTICE.
It had better *not* be a NOTICE, because there is no attached client
to forward the message to.
There is some confusion in the elog() design between message severity
level and message destination, viz DEBUG goes only to postmaster log,
NOTICE and up go to client and log. And then we have a separate
DebugLevel variable that controls how many places will emit DEBUG
messages. It might be better to unify this into a single mechanism.
Maybe replace
if (DebugLevel > 2)
elog(DEBUG, ...)
with
elog(DEBUG2, ...)
and then have two GUC variables consulted by elog that tell the
minimum message level to send to the log and the client respectively.
regards, tom lane