From: Michael Paquier <michael@paquier.xyz>
To: Aleksander Alekseev <aleksander@timescale.com>
Cc: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Cc: Sven Klemm <sven@timescale.com>
Subject: Re: Fix dropped object handling in pg_event_trigger_ddl_commands
Date: Fri, 11 Jun 2021 21:36:57 +0900
Message-ID: <YMNY6RGPBRCeLmFb@paquier.xyz> (raw)
In-Reply-To: <CAJ7c6TPNVsmVHgU69=hUFfBNLDOU8g+p_mZmBXzc-kWDG98NvA@mail.gmail.com>
References: <YMBRvAIZxJyQE5fv@paquier.xyz>
<202106091355.sphciftmvqds@alvherre.pgsql>
<YMHIQAdUA7LkrsFZ@paquier.xyz>
<YMLcsJrjWAYs/7SL@paquier.xyz>
<CAJ7c6TPNVsmVHgU69=hUFfBNLDOU8g+p_mZmBXzc-kWDG98NvA@mail.gmail.com>
On Fri, Jun 11, 2021 at 11:00:40AM +0300, Aleksander Alekseev wrote:
> The last argument should be `false` then.
Hm, nope. I think that we had better pass true as argument here.
First, this is more consistent with the identity lookup (OK, it does
not matter as we would have discarded the object after the identity
lookup anyway, but any future shuffling of this code may not be that
wise). Second, now that I look at it, getObjectTypeDescription() can
never be NULL as we have fallback names for relations, routines and
constraints for all object types so the buffer will be filled with
some data. Let's replace the bottom of getObjectTypeDescription()
that returns now NULL by Assert(buffer.len > 0). This code is new as
of v14, so it is better to adjust that sooner than later.
--
Michael
Attachments:
signature.asc (application/pgp-signature, 832B) download
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: michael@paquier.xyz, aleksander@timescale.com, alvherre@alvh.no-ip.org, pgsql-hackers@lists.postgresql.org, sven@timescale.com
Subject: Re: Fix dropped object handling in pg_event_trigger_ddl_commands
In-Reply-To: <YMNY6RGPBRCeLmFb@paquier.xyz>
* 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