From: Tomas Vondra <tomas.vondra@2ndquadrant.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-hackers@postgresql.org
Subject: Re: Allowing ALTER TYPE to change storage strategy
Date: Fri, 6 Mar 2020 14:42:18 +0100
Message-ID: <20200306134218.rgcaddnbcudcu5hm@development> (raw)
In-Reply-To: <13399.1583448404@sss.pgh.pa.us>
References: <20200229012511.7h23frunvvxwai7q@development>
<9226.1582940133@sss.pgh.pa.us>
<10968.1583176270@sss.pgh.pa.us>
<20200302220531.cdz4rlbw5gmcicsa@development>
<30065.1583347198@sss.pgh.pa.us>
<14527.1583363728@sss.pgh.pa.us>
<27393.1583366202@sss.pgh.pa.us>
<20200305190513.y4j3ckkvpzrgiy2y@development>
<17431.1583437964@sss.pgh.pa.us>
<13399.1583448404@sss.pgh.pa.us>
On Thu, Mar 05, 2020 at 05:46:44PM -0500, Tom Lane wrote:
>I wrote:
>> If not, we probably should bite the bullet and go for #1, since
>> I have little doubt that we'll need that someday anyway.
>> The trick will be to keep down the cache invalidation overhead...
>
>Here's a version that does it like that. I'm less worried about the
>overhead than I was before, because I realized that we already had
>a syscache callback for pg_type there. And it was being pretty
>stupid about which entries it reset, too, so this version might
>actually net out as less overhead (in some workloads anyway).
>
>For ease of review I just added the new TCFLAGS value out of
>sequence, but I'd be inclined to renumber the bits back into
>sequence before committing.
>
LGTM. If I had to nitpick, I'd say that the example in docs should be
ALTER TYPE mytype SET (
SEND = mytypesend,
RECEIVE = mytyperecv
);
i.e. with uppercase SEND/RECEIVE, because that's how we spell it in
other examples in CREATE TYPE etc.
regards
--
Tomas Vondra http://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
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-hackers@postgresql.org
Cc: tomas.vondra@2ndquadrant.com, tgl@sss.pgh.pa.us
Subject: Re: Allowing ALTER TYPE to change storage strategy
In-Reply-To: <20200306134218.rgcaddnbcudcu5hm@development>
References: <20200229012511.7h23frunvvxwai7q@development> <9226.1582940133@sss.pgh.pa.us> <10968.1583176270@sss.pgh.pa.us> <20200302220531.cdz4rlbw5gmcicsa@development> <30065.1583347198@sss.pgh.pa.us> <14527.1583363728@sss.pgh.pa.us> <27393.1583366202@sss.pgh.pa.us> <20200305190513.y4j3ckkvpzrgiy2y@development> <17431.1583437964@sss.pgh.pa.us> <13399.1583448404@sss.pgh.pa.us> <20200306134218.rgcaddnbcudcu5hm@development>
* 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