Move catalog toast table and index declarations

From: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
To: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Move catalog toast table and index declarations
Date: 2020-10-22 10:21:11
Message-ID: c7cc82d6-f976-75d6-2e3e-b03d2cab26bb@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

As discussed in [0], here are patches to move the system catalog toast
table and index declarations from catalog/toasting.h and
catalog/indexing.h to the respective parent tables' catalog/pg_*.h
files. I think it's clearly better to have everything together like this.

The original reason for having it split was that the old genbki system
produced the output in the order of the catalog files it read, so all
the toasting and indexing stuff needed to come separately. But this is
no longer the case.

The resulting postgres.bki file has some ordering differences *within*
the toast and index groups, but these should not be significant. (It's
basically done in the order of the parent catalogs now rather than
whatever the old file order was.)

In this patch set, I moved the DECLARE_* lines as is. In the discussion
[0] some ideas were floated for altering or tweaking these things, but I
suggest that can be undertaken as a separate patch set.

[0]:
https://www.postgresql.org/message-id/20201006201549.em2meighuapttl7n%40alap3.anarazel.de

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Attachment Content-Type Size
0001-Move-catalog-toast-table-declarations.patch text/plain 27.3 KB
0002-Move-catalog-index-declarations.patch text/plain 79.4 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Masahiko Sawada 2020-10-22 10:38:30 Re: Resetting spilled txn statistics in pg_stat_replication
Previous Message Amit Kapila 2020-10-22 09:54:59 Re: [Patch] Optimize dropping of relation buffers using dlist