pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Andres Freund <andres@anarazel.de>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Unified logging system for command-line programs
Date: Thu, 3 Jan 2019 22:38:17 +0100
Message-ID: <d6e0e58c-e103-c287-b410-2c872067e020@2ndquadrant.com> (raw)
In-Reply-To: <6174.1546549274@sss.pgh.pa.us>
References: <6a609b43-4f57-7348-6480-bd022f924310@2ndquadrant.com>
	<21141.1546199123@sss.pgh.pa.us>
	<20181231155557.7mokxwg7fnvoxd4a@alap3.anarazel.de>
	<841dd9fb-3550-dce0-e9ff-8f64cac9f15d@2ndquadrant.com>
	<20190103180315.o4gh3id5quh5aebc@alap3.anarazel.de>
	<a7c07b9c-8aa4-f9bb-e9eb-30111b732645@2ndquadrant.com>
	<6174.1546549274@sss.pgh.pa.us>

On 03/01/2019 22:01, Tom Lane wrote:
> I envisioned that we'd have a wrapper in which
> non-error ereports() map directly onto what you're calling
> pg_log_debug, pg_log_warning, etc,

My code does that, but the other way around.  (It's easier that way than
to unpack ereport() invocations.)

> while ereport(ERROR) has the
> effect of writing a message and then calling exit(1).

The problem is that in majority of cases the FRONTEND code, as it is
written today, doesn't want to exit() after an error.

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services




view thread (27+ messages)  latest in thread

Message-ID: <d6e0e58c-e103-c287-b410-2c872067e020@2ndquadrant.com>
Permalink:  ../d6e0e58c-e103-c287-b410-2c872067e020@2ndquadrant.com/
Also on:    postgresql.org/message-id/d6e0e58c-e103-c287-b410-2c872067e020@2ndquadrant.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: peter.eisentraut@2ndquadrant.com, tgl@sss.pgh.pa.us, andres@anarazel.de
  Subject: Re: Unified logging system for command-line programs
  In-Reply-To: <d6e0e58c-e103-c287-b410-2c872067e020@2ndquadrant.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox