From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Robert Haas <robertmhaas(at)gmail(dot)com> |
Cc: | Dimitri Fontaine <dimitri(at)2ndquadrant(dot)fr>, Andres Freund <andres(at)2ndquadrant(dot)com>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Heikki Linnakangas <hlinnakangas(at)vmware(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Dumping an Extension's Script |
Date: | 2012-12-05 23:49:17 |
Message-ID: | 18054.1354751357@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> In other words, the first paragraph is arguing for something like the
> notion of an extension template - the ability to store the extension
> files inside the server, in cases where you don't want them to appear
> in the file system. But perhaps implemented using functions rather
> than dedicated SQL syntax. But regardless of the concrete syntax, the
> first paragraph is proposing that we have something conceptually
> similar to:
> CREATE TEMPLATE yadda;
> ALTER TEMPLATE yadda ADD FILE 'yadda--1.0.sql' CONTENT $$...$$;
> Given that context, the second paragraph is intended as a suggestion
> that we should have something like pg_dump --no-templates -- which
> would still emit any CREATE EXTENSION commands, but not any
> CREATE/ALTER TEMPLATE commands - so if you relied on any templates in
> setting up the old cluster, the new cluster would need to have the
> files installed in the usual place. It was not a suggestion that we
> shoehorn the file management into CREATE / ALTER EXTENSION as you are
> proposing here; the first paragraph expresses my opinion, which hasn't
> changed between then and now, that that's a bad design.
FWIW, the more I think about it the more I like the notion of treating
"extension templates" as a separate kind of object. I do see value in
storing them inside the database system: transactional safety, the
ability to identify an owner, etc etc. But conflating this
functionality with installed extensions is just going to create
headaches.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Simon Riggs | 2012-12-05 23:49:42 | Re: Enabling Checksums |
Previous Message | Robert Haas | 2012-12-05 23:47:38 | Re: Commits 8de72b and 5457a1 (COPY FREEZE) |