Re: Bytea PL/Perl transform

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Ivan Panchenko <wao(at)mail(dot)ru>
Cc: Peter Eisentraut <peter(at)eisentraut(dot)org>, pgsql-hackers(at)lists(dot)postgresql(dot)org, Greg Sabino Mullane <htamfids(at)gmail(dot)com>
Subject: Re: Bytea PL/Perl transform
Date: 2023-07-14 20:27:22
Message-ID: 3450081.1689366442@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

=?UTF-8?B?SXZhbiBQYW5jaGVua28=?= <wao(at)mail(dot)ru> writes:
> Четверг, 6 июля 2023, 14:48 +03:00 от Peter Eisentraut < peter(at)eisentraut(dot)org >:
>> If the transform deals with a built-in type, then they should just be
>> added to the respective pl extension directly.

> The new extension bytea_plperl can be easily moved into plperl now, but what should be do with the existing ones, namely jsonb_plperl and bool_plperl ?
> If we leave them where they are, it would be hard to explain why some transforms are inside plperl while other ones live separately. If we move them into plperl also, wouldn’t it break some compatibility?

It's kind of a mess, indeed. But I think we could make plperl 1.1
contain the additional transforms and just tell people they have
to drop the obsolete extensions before they upgrade to 1.1.
Fortunately, it doesn't look like functions using a transform
have any hard dependency on the transform, so "drop extension
jsonb_plperl" followed by "alter extension plperl update" should
work without cascading to all your plperl functions.

Having said that, we'd still be in the position of having to
explain why some transforms are packaged with plperl and others
not. The distinction between built-in and contrib types might
be obvious to us hackers, but I bet a lot of users see it as
pretty artificial. So maybe the existing packaging design is
fine and we should just look for a way to reduce the code
duplication.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tomas Vondra 2023-07-14 20:31:57 Re: index prefetching
Previous Message Tom Lane 2023-07-14 19:50:59 Re: CommandStatus from insert returning when using a portal.