Re: Only one version can be installed when using extension_control_path

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Matheus Alcantara <matheusssilv97(at)gmail(dot)com>
Cc: Pierrick <pierrick(dot)chovelon(at)dalibo(dot)com>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Only one version can be installed when using extension_control_path
Date: 2025-09-08 15:23:03
Message-ID: CAKFQuwbR1Fzr8yRuMW=N1UMA1cTpFcqZe9bW_-ZF8=Ba2Ud2=w@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Monday, September 8, 2025, Matheus Alcantara <matheusssilv97(at)gmail(dot)com>
wrote:

> On Fri Sep 5, 2025 at 11:22 AM -03, Pierrick wrote:
> > If the same extension is in two different paths mentioned in
> > extension_control_path,
> > it is impossible to install the version of the last one.
> >
> > postgres=# show extension_control_path ;
> > extension_control_path
> > ------------------------------------------------------------
> -----------------
> > $system:/extensions/meilleureextension/share:/
> extensions/monextension/share
> > (1 row)
> >
> > postgres=# select * from pg_available_extensions where name like '%mon%';
> > name | default_version | installed_version | comment
> > --------------+-----------------+-------------------+---------------
> > monextension | 2.0 | | Meilleure
> > monextension | 1.0 | | Mon extension
> >
>

> On this step it will search the .control
> file on paths at extension_control_path in order and it will use the
> first one that it finds and based on the .control file found it will
> install the extension using the version specified on the command.
>

Then pg_available_extensions seems broken - it lists extensions as
available that are not accessible to the user due to this policy. Maybe we
need to add something indicating that certain rows are hidden behind the
present path setting which would need to be changed if one wishes to
install them. Also seems like the extension location should be part of the
output too.

David J.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Zsolt Parragi 2025-09-08 15:31:07 Re: OAuth client code doesn't work with Google OAuth
Previous Message Paul Ohlhauser 2025-09-08 15:20:19 Re: [PG19-3 PATCH] Don't ignore passfile