Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ql2vw-000oHD-BA for pgsql-hackers@arkaria.postgresql.org; Tue, 26 Sep 2023 07:56:40 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1ql2vu-009T1i-Jk for pgsql-hackers@arkaria.postgresql.org; Tue, 26 Sep 2023 07:56:38 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ql2vu-009T1U-7o for pgsql-hackers@lists.postgresql.org; Tue, 26 Sep 2023 07:56:38 +0000 Received: from mail1.dalibo.net ([51.159.93.128] helo=mail.dalibo.com) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ql2vn-007doD-4d for pgsql-hackers@lists.postgresql.org; Tue, 26 Sep 2023 07:56:37 +0000 Received: from [192.168.1.87] (59.70.69.37.rev.sfr.net [37.69.70.59]) by mail.dalibo.com (Postfix) with ESMTPSA id A67AF1F8EB; Tue, 26 Sep 2023 09:56:28 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=dalibo.com; s=a; t=1695714988; bh=xqoKP4IfslCuk+iux90rGnIQ1qVBKdmW5yow9phOrmU=; h=Subject:From:To:Cc:Date:In-Reply-To:References:From; b=l2NPZ6ftVzpiugp3SouLPIzbuIkqvLJEpB8CNAnGZjDnrucv0y/5Bi0cTLjYVV8kH r5gZKDaXT9iief7Wwg02Ei80bbqxzGkTBtWpZ6buMu9y+p5CkJuY/1mcsinEdL0jMq YqvbQcIFThY/c/IwRScdUH+0ZD9PozHA+MWrbqQo= Message-ID: Subject: Re: logfmt and application_context From: =?ISO-8859-1?Q?=C9tienne?= BERSAC To: Daniel Gustafsson Cc: pgsql-hackers@lists.postgresql.org Date: Tue, 26 Sep 2023 09:56:27 +0200 In-Reply-To: References: <7e5a39c66e85d3794f04936bf723df8ae2a0992d.camel@dalibo.com> Organization: DALIBO Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.46.4-2 MIME-Version: 1.0 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi Daniel, Thanks for the feedback. Le mardi 05 septembre 2023 =C3=A0 11:35 +0200, Daniel Gustafsson a =C3=A9cr= it=C2=A0: > > On 30 Aug 2023, at 14:36, =C3=89tienne BERSAC wrote: >=20 > > ..what do you think of having logfmt output along json and CSV ? >=20 > Less ideal is > that there is no official formal definition of what logfmt is [...]=C2=A0= If we add > support for it, can we reasonably expect that what we emit is what consum= ers of > it assume it will look like? I didn't know logfmt had variation. Do you have a case of incompatibility ? Anyway, I think that logfmt will be better handled inside Postgres rather than in an extension due to limitation in syslogger extendability. I could send a patch if more people are interested in this. What do you think about application_context as a way to render e.g. a web request UUID to all backend log messages ? Regards, =C3=89tienne