From: | Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr> |
---|---|
To: | Sergey Muraviov <sergey(dot)k(dot)muraviov(at)gmail(dot)com> |
Cc: | PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: extension_control_path |
Date: | 2014-01-27 20:42:16 |
Message-ID: | m27g9lma1j.fsf@2ndQuadrant.fr |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
Sergey Muraviov <sergey(dot)k(dot)muraviov(at)gmail(dot)com> writes:
> Now patch applies cleanly and works. :-)
Cool ;-)
> But I have some notes:
>
> 1. There is an odd underscore character in functions
> find_in_extension_control_path and list_extension_control_paths:
> \"extension_control__path\""
Fixed in the new version of the patch, attached.
> 2. If we have several versions of one extension in different directories
> (which are listed in extension_control_path parameter) then we
> get strange output from pg_available_extensions and
> pg_available_extension_versions views (Information about extension, whose
> path is at the beginning of the list, is duplicated). And only one version
> of the extension can be created.
Fixed.
> 3. It would be fine to see an extension control path
> in pg_available_extensions and pg_available_extension_versions views (in
> separate column or within of extension name).
I think the on-disk location is an implementation detail and decided in
the attached version not to change those system view definitions.
> 4. Perhaps the CREATE EXTENSION command should be improved to allow
> creation of the required version of the extension.
> So we can use different versions of extensions in different databases.
Fixed in the attached.
I also fixed ALTER EXTENSION UPDATE to search for udpate scripts in the
same directory where the main control file is found, but I suspect this
part requires more thinking.
When we ALTER EXTENSION UPDATE we might now have several places where we
find extname.control files, with possibly differents default_version
properties.
In the attached, we select the directory containing the control file
where default_version matches the already installed extension version.
That matches with a model where the new version of the extension changes
the default_version in an auxiliary file.
We might want to instead match on the default_version in the control
file to match with the new version we are asked to upgrade to.
Regards,
--
Dimitri Fontaine
http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support
Attachment | Content-Type | Size |
---|---|---|
extension_control_path.v1.patch | text/x-patch | 28.7 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Geoghegan | 2014-01-27 20:44:02 | Re: Storing pg_stat_statements query texts externally, pg_stat_statements in core |
Previous Message | Tom Lane | 2014-01-27 20:39:39 | Re: Storing pg_stat_statements query texts externally, pg_stat_statements in core |