tableam: New callback relation_fetch_toast_slice.
Robert Haas <rhaas@postgresql.org>
tableam: New callback relation_fetch_toast_slice. Instead of always calling heap_fetch_toast_slice during detoasting, invoke a table AM callback which, when the toast table is a heap table, will be heap_fetch_toast_slice. This makes it possible for a table AM other than heap to be used as a TOAST table. It also completes the series of commits intended to improve the interaction of tableam with TOAST that began with commit 8b94dab06617ef80a0901ab103ebd8754427ef5a; detoast.c is now, hopefully, fully AM-independent. Patch by me, reviewed by Andres Freund and Peter Eisentraut. Discussion: http://postgr.es/m/CA+TgmoZv-=2iWM4jcw5ZhJeL18HF96+W1yJeYrnGMYdkFFnEpQ@mail.gmail.com
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/access/common/detoast.c | modified | +6 −193 |
| src/backend/access/heap/heapam_handler.c | modified | +1 −0 |
| src/backend/access/heap/heaptoast.c | modified | +182 −0 |
| src/include/access/heaptoast.h | modified | +10 −0 |
| src/include/access/tableam.h | modified | +46 −0 |
Discussion
- tableam vs. TOAST 50 messages · 2019-05-17 → 2020-01-07