Re: logical replication worker accesses catalogs in error context callback

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>
Cc: Zhihong Yu <zyu@yugabyte.com>, Masahiko Sawada <sawada.mshk@gmail.com>, Andres Freund <andres@anarazel.de>, PostgreSQL-development <pgsql-hackers@postgresql.org>, Peter Eisentraut <peter_e@gmx.net>, Petr Jelinek <petr@2ndquadrant.com>, Alvaro Herrera <alvherre@alvh.no-ip.org>
Date: 2021-07-02T20:07:28Z
Lists: pgsql-hackers
Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com> writes:
>> << Attaching v5-0001 here again for completion >>
>> I'm attaching v5-0001 patch that avoids printing the column type names
>> in the context message thus no cache lookups have to be done in the
>> error context callback. I think the column name is enough to know on
>> which column the error occurred and if required it's type can be known
>> by the user. This patch gets rid of printing local and remote type
>> names in slot_store_error_callback and also
>> logicalrep_typmap_gettypname because it's unnecessary. Thoughts?

I've now pushed this patch.  I noted that once we drop
logicalrep_typmap_gettypname, there's really nothing using
the LogicalRepTypMap table at all, so I nuked that too.
(We can always recover the code from the git archives if
some reason to use it emerges.)

Didn't look at 0002 yet.

			regards, tom lane



Commits

  1. Avoid doing catalog lookups in postgres_fdw's conversion_error_callback.

  2. Don't try to print data type names in slot_store_error_callback().

  3. logical replication: fix OID type mapping mechanism

  4. Improve sys/catcache performance.

  5. Logical replication