Re: [COMMITTERS] pgsql: Allow units to be specified in relation option setting value.
От | Fujii Masao |
---|---|
Тема | Re: [COMMITTERS] pgsql: Allow units to be specified in relation option setting value. |
Дата | |
Msg-id | CAHGQGwFtd6OYy9iCzsspH9eAOW8aTmK4RZUoraUDYj9nRvYW1g@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: [COMMITTERS] pgsql: Allow units to be specified in relation option setting value. (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: [COMMITTERS] pgsql: Allow units to be specified in relation
option setting value.
|
Список | pgsql-hackers |
On Thu, Aug 28, 2014 at 11:14 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote: > Michael Paquier <michael.paquier@gmail.com> writes: >> The patch attached fixes pg_upgrade by putting quotes when generating >> reloptions and it passes check-world. I imagine that having quotes by >> default in the value of reloptions in pg_class is the price to pay for >> supporting units. If this is not considered as a correct approach, >> then reverting the patch would be wiser I guess. > > Ugh. I'm not sure what the best solution is, but I don't think I like > that one. Another approach is to change pg_dump so that it encloses the relopt values with single quotes. This is the same approach as what pg_dumpall does for database or role-specific settings. Obvious drawback of this approach is that it prevents pg_dump with 9.4 or before from outputting the restorable dump. Maybe we can live with this because there is no guarantee that older version of pg_dump can work properly with newer major version of server. But maybe someone cannot live with that. Not sure. Further other approach is to change the reloptions code so that it always stores the plain value without the units (i.e., 1000 is stored if 1s is specified in autovacuum_vacuum_cost_delay)in pg_class. This approach doesn't prevent older version of pg_dump from taking the dump from v9.5 server. One drawback of this approach is that reloption values are always stored without the units, which might make it a bit hard for a user to see the reloption values from pg_class. Regards, -- Fujii Masao
В списке pgsql-hackers по дате отправления: