Re: Proposal: Adding json logging

From: John W Higgins <wishdev(at)gmail(dot)com>
To: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: Proposal: Adding json logging
Date: 2018-04-15 18:28:37
Message-ID: CAPhAwGwtiVUvkO5U0PwFwei9EG=o=5Jp-5xMgd+uyUTqvt-McQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sun, Apr 15, 2018 at 11:08 AM, David Arnold <dar(at)xoe(dot)solutions> wrote:

> >This would appear to solve multiline issues within Fluent.....
> >https://docs.fluentd.org/v0.12/articles/parser_multiline
>
> I definitely looked at that, but what guarantees do I have that the
> sequence is always ERROR/STATEMENT/DETAIL? And not the other way round?
>

Have you asked that question? You seem to at least have opened the source
code - did you try to figure out what the logging format is?

> And it only works with tail logging from log file so I cannot use a native
> docker logging driver which streams event by event.
> This again prohibits me the usage of host-global docker logging driver
> configuration as my standard option for host provisioning.
>

What does JSON logging have to do with "event by event" streaming?

Docker also lists Fluent as a standard driver for logging [1] - along with
syslog and a variety of others. It's outstanding that JSON is their default
- but they seem perfectly happy to accomodate plenty of other options. I
don't seem how there is a conflict here.

I was also under the impression things like Fluent existed for the sole
purpose of taking disparate logging solutions and bringing them under one
roof - it would seem like it wants nothing more than for PostgreSQL to do
as it pleases with the logs and they will pick it up and run with it.

If there is an actual ambiguity with how logs are produced - I'm certain
plenty of folks on here would like to solve that issue immediately. But I
don't see anything stopping Docker/Fluent from using what is currently on
the table.

John

[1] -
https://docs.docker.com/config/containers/logging/configure/#supported-logging-drivers

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message David Arnold 2018-04-15 19:16:43 Re: Proposal: Adding json logging
Previous Message David Arnold 2018-04-15 18:13:52 Re: Proposal: Adding json logging