Re: WIP: a way forward on bootstrap data
Alvaro Herrera <alvherre@alvh.no-ip.org>
From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: Robert Haas <robertmhaas@gmail.com>
Cc: John Naylor <jcnaylor@gmail.com>, David Fetter <david@fetter.org>, Peter Eisentraut <peter.eisentraut@2ndquadrant.com>, pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2017-12-22T14:31:54Z
Lists: pgsql-hackers
Robert Haas wrote: > On Thu, Dec 21, 2017 at 5:32 PM, Alvaro Herrera <alvherre@alvh.no-ip.org> wrote: > > Hmm, patch 0008 removes data lines from the .h but leaves the dependent > > OID define lines around: > > Just a question here -- do we actually have consensus on doing the > stuff that these patches do? Because I'm not sure we do. My reading of the old threads (linked provided by John in his initial email in this thread) is that we have a consensus that we want to get rid of the old data representation, because it causes endless amount of pain. The proposed format seems to satisfy the constraints that we all discussed, namely 1. be easier to modify than the current format, 2. in particular, allow for default values on certain columns 3. not cause git merge problems because of too similar lines in every record 4. not require onerous Perl modules The one thing we seem to lack is a tool to edit the data files, as you suggested[1]. Stephen Frost mentioned[2] that we could do this by allowing the .data files be loaded in a database table, have the changes made via SQL, then have a way to create an updated .data file. Tom said[3] he didn't like that particular choice. So we already have Catalog.pm that (after these patches) knows how to load .data files; we could use that as a basis to enable easy oneliners to do whatever editing is needed. Also, the CPP symbols remaining in the pg_*.h that I commented yesterday was already mentioned[4] before. [1] https://www.postgresql.org/message-id/CA%2BTgmoa4%3D5oz7wSMcLNLh8h6cXzPoxxNJKckkdSQA%2BzpUG0%2B0A%40mail.gmail.com [2] https://www.postgresql.org/message-id/20150304150712.GV29780%40tamriel.snowman.net [3] https://www.postgresql.org/message-id/24766.1478821303%40sss.pgh.pa.us [4] https://www.postgresql.org/message-id/15697.1479161432@sss.pgh.pa.us -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Commits
-
Clarify handling of special-case values in bootstrap catalog data.
- 45c6d75f8cd2 11.0 landed
-
Replace our traditional initial-catalog-data format with a better design.
- 372728b0d495 11.0 landed
-
Faster partition pruning
- 9fdb675fc5d2 11.0 cited
-
Minor cleanup in genbki.pl.
- 8d90b4d01a61 11.0 landed
-
Trivial adjustments in preparation for bootstrap data conversion.
- a351679c806e 11.0 landed
-
Remove hard-coded schema knowledge about pg_attribute from genbki.pl
- 49c784ece766 11.0 landed
-
Minor edits to catalog files and scripts
- 9373baa0f764 11.0 landed
-
Hide most variable-length fields from Form_pg_* structs
- 8137f2c32322 9.2.0 cited