Re: Extensions, patch 22 (cleanup, review, cleanup) - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: Extensions, patch 22 (cleanup, review, cleanup)
Date
Msg-id 1292882554-sup-8184@alvh.no-ip.org
Whole thread Raw
In response to Extensions, patch 22 (cleanup, review, cleanup)  (Dimitri Fontaine <dimitri@2ndQuadrant.fr>)
Responses Re: Extensions, patch 22 (cleanup, review, cleanup)  (Dimitri Fontaine <dimitri@2ndQuadrant.fr>)
List pgsql-hackers
Excerpts from Dimitri Fontaine's message of lun dic 20 18:35:44 -0300 2010:
> Hi,
>
> From last round of review from Robert and Álvaro, here's the patch
> version 22. Changes:

I noticed this bit in the docs:

     The admin
     function <link linkend="functions-extension">pg_extension_flag_dump</link>
     can be used to revert the default <literal>pg_dump</literal> policy
     about objects that belong to an extension and force the flagged objects
     to be part of the backups.

However, the code to that function contains this bit:

    /*
     * CREATE EXTENSION is superuser only and we check we're in that code
     * path, so we don't add another explicit check for superuser here.
     */
    if (!create_extension)
        ereport(ERROR,
                (errmsg("this function can only be used from CREATE EXTENSION")));


So presumably this shouldn't be documented because it cannot be called
anyway?

To be honest I don't understand the purpose of this part of the patch.

I attach some minor fixes while reading it over.  I compiled but didn't
run it :-)

--
Álvaro Herrera <alvherre@commandprompt.com>
The PostgreSQL Company - Command Prompt, Inc.
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

Attachment

pgsql-hackers by date:

Previous
From: Florian Pflug
Date:
Subject: Re: serializable lock consistency
Next
From: Martijn van Oosterhout
Date:
Subject: Re: Extensions, patch v20 (bitrot fixes)