Re: WIP: a way forward on bootstrap data
Robert Haas <robertmhaas@gmail.com>
From: Robert Haas <robertmhaas@gmail.com>
To: Mark Dilger <hornschnorter@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>, John Naylor <jcnaylor@gmail.com>, pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2018-04-25T20:00:52Z
Lists: pgsql-hackers
On Wed, Apr 25, 2018 at 3:44 PM, Mark Dilger <hornschnorter@gmail.com> wrote:
> There still seems to be a lot of boilerplate in the .dat files
> that could be eliminated. Tom mentioned upthread that he did
> not want too much magic in genbki.pl or Catalog.pm, but I think
> I can propose putting some magic in the header files themselves.
>
> Take, for example, some of the fields in pg_type.dat. I'll elide
> the ones I'm not talking about with ...:
>
>
> {... typname => 'X', ... typinput => 'Xin', typoutput => 'Xout',
> typreceive => 'Xrecv', typsend => 'Xsend', ... },
-1 for trying to automate this. It varies between fooin and foo_in,
and it'll be annoying to have to remember which one happens
automatically and which one needs an override.
> If we changed pg_proc.h:
>
> /* procedure source text */
> - text prosrc BKI_FORCE_NOT_NULL;
> + text prosrc BKI_DEFAULT("${proname}") BKI_FORCE_NOT_NULL;
>
> we could remove the prosrc field from many of the records, which would
> do a better job of calling attention to the remaining records where the
> C function name differs from the SQL function name.
That one I kinda like.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
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