Re: logicalrep_message_type throws an error
Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>
From: Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>
To: Amit Kapila <amit.kapila16@gmail.com>
Cc: Masahiko Sawada <sawada.mshk@gmail.com>,
Alvaro Herrera <alvherre@alvh.no-ip.org>, Euler Taveira <euler@eulerto.com>, pgsql-hackers@lists.postgresql.org
Date: 2023-07-17T13:49:42Z
Lists: pgsql-hackers
On Sat, Jul 15, 2023 at 12:57 PM Amit Kapila <amit.kapila16@gmail.com> wrote: > > > > Since the numerical value is important only in invalid message type > > cases, how about using a format like "??? (88)" in unknown message > > type cases, in both error and context messages? > > > > Do you have something like attached in mind? Prologue of psprintf() says * Errors are not returned to the caller, but are reported via elog(ERROR) * in the backend, or printf-to-stderr-and-exit() in frontend builds. * One should therefore think twice about using this in libpq. If an error occurs in psprintf(), it will throw an error which will override the original error. I think we should avoid any stuff that throws further errors. -- Best Wishes, Ashutosh Bapat
Commits
-
Fix the display of UNKNOWN message type in apply worker.
- d38ad8e31dee 17.0 landed
- ad486b0eaef4 16.0 landed
- 2864eb977a6e 15.4 landed