From: | Sergey Muraviov <sergey(dot)k(dot)muraviov(at)gmail(dot)com> |
---|---|
To: | Dimitri Fontaine <dimitri(at)2ndquadrant(dot)fr> |
Cc: | PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: extension_control_path |
Date: | 2014-01-24 17:43:12 |
Message-ID: | CAJTaR333_UWTGwdyshDNM4jgQmFV2wmbbBBYt5dyfZjynf4qCw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi
Now patch applies cleanly and works. :-)
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\""
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.
See examples:
/extensions/
├── postgis-2.0.4
│ ├── postgis--2.0.4.sql
│ └── postgis.control
└── postgis-2.1.1
├── postgis--2.1.1.sql
└── postgis.control
=================================================
postgresql.conf:
extension_control_path =
'/extensions/postgis-2.0.4:/extensions/postgis-2.1.1'
postgres=# table pg_catalog.pg_available_extensions;
name | default_version | installed_version |
comment
---------+-----------------+-------------------+---------------------------------------------------------------------
postgis | 2.0.4 | | PostGIS geometry,
geography, and raster spatial types and functions
postgis | 2.0.4 | | PostGIS geometry,
geography, and raster spatial types and functions
(2 rows)
postgres=# table pg_catalog.pg_available_extension_versions;
name | version | installed | superuser | relocatable | schema |
requires | comment
---------+---------+-----------+-----------+-------------+--------+----------+---------------------------------------------------------------------
postgis | 2.0.4 | f | t | t | |
| PostGIS geometry, geography, and raster spatial types and functions
postgis | 2.0.4 | f | t | t | |
| PostGIS geometry, geography, and raster spatial types and functions
(2 rows)
=================================================
postgresql.conf:
extension_control_path =
'/extensions/postgis-2.1.1:/extensions/postgis-2.0.4'
postgres=# table pg_catalog.pg_available_extensions;
name | default_version | installed_version |
comment
---------+-----------------+-------------------+---------------------------------------------------------------------
postgis | 2.1.1 | | PostGIS geometry,
geography, and raster spatial types and functions
postgis | 2.1.1 | | PostGIS geometry,
geography, and raster spatial types and functions
(2 rows)
postgres=# create extension postgis;
CREATE EXTENSION
postgres=# SELECT PostGIS_version();
postgis_version
---------------------------------------
2.1 USE_GEOS=1 USE_PROJ=1 USE_STATS=1
(1 row)
postgres=# table pg_catalog.pg_available_extensions;
name | default_version | installed_version |
comment
---------+-----------------+-------------------+---------------------------------------------------------------------
postgis | 2.1.1 | 2.1.1 | PostGIS geometry,
geography, and raster spatial types and functions
postgis | 2.1.1 | 2.1.1 | PostGIS geometry,
geography, and raster spatial types and functions
(2 rows)
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).
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.
PS
Sorry for my English.
2014/1/24 Fabrízio de Royes Mello <fabriziomello(at)gmail(dot)com>
>
> On Fri, Jan 24, 2014 at 6:57 AM, Dimitri Fontaine <dimitri(at)2ndquadrant(dot)fr>
> wrote:
> >
> > Sergey Muraviov <sergey(dot)k(dot)muraviov(at)gmail(dot)com> writes:
> > > I can't apply the patch.
> >
> > Did you try using the `patch`(1) command?
> >
> > The PostgreSQL project policy is to not use the git format when sending
> > patches to the mailing list, prefering the context diff format. So you
> > need to resort to using the basic patch commands rather than the modern
> > git tooling. See also:
> >
> > http://wiki.postgresql.org/wiki/Submitting_a_Patch
> >
> > Patches must be in a format which provides context (eg: Context
> > Diff); 'normal' or 'plain' diff formats are not acceptable.
> >
>
> Would be nice if we can use "git apply" command...
>
> :-)
>
> --
> Fabrízio de Royes Mello
> Consultoria/Coaching PostgreSQL
> >> Timbira: http://www.timbira.com.br
> >> Blog sobre TI: http://fabriziomello.blogspot.com
> >> Perfil Linkedin: http://br.linkedin.com/in/fabriziomello
> >> Twitter: http://twitter.com/fabriziomello
>
--
Best regards,
Sergey Muraviov
From | Date | Subject | |
---|---|---|---|
Next Message | Josh Berkus | 2014-01-24 17:44:27 | Re: Why do we let autovacuum give up? |
Previous Message | Noah Misch | 2014-01-24 17:14:13 | Re: UNION ALL on partitioned tables won't use indices. |