RE: Include schema-qualified names in publication error messages (generalised to all of LR).

From: "Hayato Kuroda (Fujitsu)" <kuroda(dot)hayato(at)fujitsu(dot)com>
To: 'Peter Smith' <smithpb2250(at)gmail(dot)com>, vignesh C <vignesh21(at)gmail(dot)com>
Cc: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Euler Taveira <euler(at)eulerto(dot)com>, Dilip Kumar <dilipbalaut(at)gmail(dot)com>, "shveta(dot)malik(at)gmail(dot)com" <shveta(dot)malik(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: RE: Include schema-qualified names in publication error messages (generalised to all of LR).
Date: 2026-10-16 08:39:12
Message-ID: OS7PR01MB183177A958E31DC4239D23BA2F59B2@OS7PR01MB18317.jpnprd01.prod.outlook.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi Peter,

+1 the basic idea. But I have a worry that translations for around 20 statements
will be invalidated because "%s.%s" will be replaced to "%s", which needs
additional work for translators (even the outcome is not changed).
Not sure the conversion wins the cost, or is it acceptable for HEAD?

Anyway, I grepped source codes under the logical/ and some codes under the commands/.
I found single RelationGetRelationName()/get_rel_name() call are retained in some
places, but seems OK. IIUC, below four types are still retained.

* replication protocol message. We have been sending them separately, and no
reasons to combine.
* table/sequence mactching between publication and subscription. We are now
passing to queries them.
* ACL checks. It's not schema-qualified even from other places, so it's OK not to
do for now.
* Subscription relkind checks. The function accepts the namespace and relation
name separately, because the remote name can be specified. It's more natural to
keep current style.

> Open question: for a temporary table, should the schema be displayed
> as "pg_temp" or "pg_temp_N"? The attached keeps "pg_temp_N", which is
> the current status quo. Anyway, after 0001 this is a one-line change
> in MsgQualifiedRelNameByRel()/...ByRelId() if the consensus is
> otherwise.

IIUC, for the current region, the pg_temp schema can be reported only backend
processes, right? If so I prefer without suffic, pg_temp. pg_temp_xxx is usable
if other processes report the temp schema, maybe like autovacuum worker.

Best regards,
Hayato Kuroda
FUJITSU LIMITED

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bertrand Drouvot 2026-10-16 08:39:23 Re: Persist slot invalidations before publishing them
Previous Message Chao Li 2026-10-16 08:36:12 Re: Fix pg_restore gzip stream validation (bug #19754)