Re: Proposal: Adding json logging - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Proposal: Adding json logging
Date
Msg-id 10502.1523739808@sss.pgh.pa.us
Whole thread Raw
In response to Re: Proposal: Adding json logging  (Andres Freund <andres@anarazel.de>)
List pgsql-hackers
Andres Freund <andres@anarazel.de> writes:
> On 2018-04-14 18:05:18 +0200, David Fetter wrote:
>> CSV is very poorly specified, which makes it at best complicated to
>> build correct parsing libraries. JSON, whatever gripes I have about
>> the format[1] is extremely well specified, and hence has excellent
>> parsing libraries.

> Worth to notice that useful json formats for logging also kinda don't
> follow standards. Either you end up with entire logfiles as one big
> array, which most libraries won't parse and makes logrotate etc really
> complicated, or you end up with some easy to parse format where newlines
> have non-standard record separator meaning.

Hmm .. that, actually, seems like a pretty serious objection.  If the beef
with CSV is that it's poorly specified and inconsistently implemented
(which is surely true), then using some nonstandard variant of JSON
doesn't seem like it's going to lead to a big step forward.

"The wonderful thing about standards is there are so many to choose from."
(variously attributed to Hopper, Tanenbaum, and others)

            regards, tom lane


pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: Setting rpath on llvmjit.so?
Next
From: Tom Lane
Date:
Subject: Re: Setting rpath on llvmjit.so?