From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Add backtrace support for error reporting
Date: Fri, 08 Nov 2019 18:52:20 +0000
Message-ID: <E1iT9Mq-0004Qu-73@gemulon.postgresql.org> (raw)
Add backtrace support for error reporting
Add some support for automatically showing backtraces in certain error
situations in the server. Backtraces are shown on assertion failure;
also, a new setting backtrace_functions can be set to a list of C
function names, and all ereport()s and elog()s from the mentioned
functions will have backtraces generated. Finally, the function
errbacktrace() can be manually added to an ereport() call to generate a
backtrace for that call.
Authors: Peter Eisentraut, Álvaro Herrera
Discussion: https://postgr.es/m//5f48cb47-bf1e-05b6-7aae-3bf2cd01586d@2ndquadrant.com
Discussion: https://postgr.es/m/CAMsr+YGL+yfWE=JvbUbnpWtrRZNey7hJ07+zT4bYJdVp4Szdrg@mail.gmail.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/71a8a4f6e36547bb060dbcc961ea9b57420f7190
Modified Files
--------------
configure | 61 +++++++++++++++++++-
configure.in | 4 ++
doc/src/sgml/config.sgml | 26 +++++++++
src/backend/utils/error/assert.c | 13 +++++
src/backend/utils/error/elog.c | 117 +++++++++++++++++++++++++++++++++++++++
src/backend/utils/misc/guc.c | 85 ++++++++++++++++++++++++++++
src/include/pg_config.h.in | 6 ++
src/include/utils/elog.h | 3 +
src/include/utils/guc.h | 2 +
9 files changed, 315 insertions(+), 2 deletions(-)
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: alvherre@alvh.no-ip.org
Subject: Re: pgsql: Add backtrace support for error reporting
In-Reply-To: <E1iT9Mq-0004Qu-73@gemulon.postgresql.org>
References: <E1iT9Mq-0004Qu-73@gemulon.postgresql.org>
* 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