Re: logging stuff - Mailing list pgsql-hackers

From Tom Lane
Subject Re: logging stuff
Date
Msg-id 12244.1060115275@sss.pgh.pa.us
Whole thread Raw
In response to Re: logging stuff  (Josh Berkus <josh@agliodbs.com>)
Responses Re: logging stuff
List pgsql-hackers
Josh Berkus <josh@agliodbs.com> writes:
> From my perspective, we could really use a "delimiter" between the
> "fields" of log output which is unlikely to appear within those fields
> instead of parsing by character count, rather than making dbname a
> special case.

Well, Andrew was arguing that space is a likely character in dbnames,
but then again it's possible to put "]" into dbnames.  I think the only
way to make this completely unambiguous would be to introduce a quoting
convention for dbnames (and usernames when those get added).  But if
the goal is to allow simple parsing of log entries, that won't improve
matters at all.

My feeling about it is that DBAs who want to automatically parse log
entries can just forbid spaces in the dbnames and usernames they allow.
The KISS principle applies here.

A variant (which'd be okay with me) is to separate these fields with
tabs instead of spaces; then the rule for DBAs would be "don't allow
tabs in db/user names".
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: TODO: trigger features
Next
From: Larry Rosenman
Date:
Subject: Re: logging stuff