From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
Cc: | Fabrízio de Royes Mello <fabriziomello(at)gmail(dot)com>, Abhijit Menon-Sen <ams(at)2ndquadrant(dot)com>, Peter Eisentraut <peter_e(at)gmx(dot)net>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Andres Freund <andres(at)2ndquadrant(dot)com>, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: [PATCH] Store Extension Options |
Date: | 2014-03-12 22:58:43 |
Message-ID: | CA+TgmoYR6YthLN0RwnA87MFDTdWWSnuM8zVsVCwW-hnF3uQMPw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, Mar 10, 2014 at 9:33 PM, Alvaro Herrera
<alvherre(at)2ndquadrant(dot)com> wrote:
> I haven't touched pg_dump yet, but if this proposed design sits well
> with everyone, my intention is that the dump output will contain the
> pg_register_option_namespace() calls necessary so that a table
> definition will be able to do the SET calls to set the values the
> original table has, and succeed. In other words, restoring a dump will
> preserve the values you had, without a need of having the module loaded
> in the new server. I think this is what was discussed. Robert, do you
> agree?
No, I wasn't imagining anything like pg_register_option_namespace().
My thought was that you'd need to have any relevant modules loaded at
restore time. In essence, patching in a new option via an extension
module would work about like adding one by patching the core code: you
need a server version that supports that option in order to set it.
I don't like the idea of using reloptions to let people attach
arbitrary unvalidated settings to tables. I consider the way things
work with GUCs to be a bug, not a feature, and definitely not
something I want to propagate into every other area of the system
where the underlying storage format happens to allow it.
I also kind of think that what you're going to find if you try to
press forward with the pg_register_option_namespace() idea is that
what you really want is CREATE RELOPTION NAMESPACE, ALTER RELOPTION
NAMESPACE, DROP RELOPTION NAMESPACE. Short of that, you're going to
end up with a bunch of kludges, I suspect. And some kind of real DDL
syntax (with better naming) is OK with me, but as you observed
elsewhere on the thread, now you're looking at a new catalog and a
bunch more complexity.
I kind of think that this is too half-baked for 9.4 and we ought to
punt it to 9.5.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Haas | 2014-03-12 23:15:20 | Re: Performance Improvement by reducing WAL for Update Operation |
Previous Message | Rukh Meski | 2014-03-12 22:19:00 | Re: 9.5: UPDATE/DELETE .. ORDER BY .. LIMIT .. |