Re: Table AM Interface Enhancements
Alexander Korotkov <aekorotkov@gmail.com>
Attachments
- 0004-Let-table-AM-override-reloptions-for-indexes-buil-v5.patch (application/octet-stream) patch v5-0004
- 0005-Notify-table-AM-about-index-creation-v5.patch (application/octet-stream) patch v5-0005
- 0003-Generalize-table-AM-API-for-INSERT-.-ON-CONFLICT-v5.patch (application/octet-stream) patch v5-0003
- 0001-Generalize-relation-analyze-in-table-AM-interface-v5.patch (application/octet-stream) patch v5-0001
- 0002-Custom-reloptions-for-table-AM-v5.patch (application/octet-stream) patch v5-0002
- 0006-Let-table-AM-insertion-methods-control-index-inse-v5.patch (application/octet-stream) patch v5-0006
- 0007-Introduce-RowRefType-which-describes-the-table-ro-v5.patch (application/octet-stream) patch v5-0007
- 0008-Introduce-RowID-bytea-tuple-identifier-v5.patch (application/octet-stream) patch v5-0008
On Fri, Mar 22, 2024 at 6:56 AM Pavel Borisov <pashkin.elfe@gmail.com> wrote: > > On Fri, 22 Mar 2024 at 08:51, Pavel Borisov <pashkin.elfe@gmail.com> wrote: >> >> Hi, Alexander! >> >> Thank you for working on this patchset and pushing some of these patches! >> >> I tried to write comments for tts_minimal_is_current_xact_tuple() and tts_minimal_getsomeattrs() for them to be the same as for the same functions for heap and virtual tuple slots, as I proposed above in the thread. (tts_minimal_getsysattr is not introduced by the current patchset, but anyway) >> >> Meanwhile I found that (never appearing) error message for tts_minimal_is_current_xact_tuple needs to be corrected. Please see the patch in the attachment. >> > I need to correct myself: it's for tts_minimal_getsysattr() not tts_minimal_getsomeattrs() Pushed. The revised rest of the patchset is attached. 0001 (was 0006) – I prefer the definition of AcquireSampleRowsFunc to stay in vacuum.h. If we move it to sampling.h then we would have to add there includes to define Relation, HeapTuple etc. I'd like to avoid this kind of change. Also, I've deleted table_beginscan_analyze(), because it's only called from tableam-specific AcquireSampleRowsFunc. Also I put some comments to heapam_scan_analyze_next_block() and heapam_scan_analyze_next_tuple() given that there are now no relevant comments for them in tableam.h. I've removed some redundancies from acquire_sample_rows(). And added comments to AcquireSampleRowsFunc based on what we have in FDW docs for this function. Did some small edits as well. As you suggested, turned back declarations for acquire_sample_rows() and compare_rows(). 0002 (was 0007) – I've turned the redundant "if", which you've pointed out, into an assert. Also, added some comments, most notably comment for TableAmRoutine.reloptions based on the indexam docs. 0007 (was 0012) – This patch doesn't make much sense if not removing ROW_MARK_COPY. What an oversight by me! I managed to remove ROW_MARK_COPY so that tests passed. Added a lot of comments and made other improvements. But the problem is that I didn't manage to research all the consequences of this patch to FDW. And I think there are open design questions. In particular how should ROW_REF_COPY work with row marks other than ROW_MARK_REFERENCE and should it work at all? This would require some consensus, and it doesn't seem feasible to achieve before FF. So, I think this is not a subject for v17. Other patches are without changes. ------ Regards, Alexander Korotkov
Commits
-
Remove extra comment at TableAmRoutine.scan_analyze_next_block
- 70a845c04a47 17.0 landed
-
revert: Generalize relation analyze in table AM interface
- 6377e12a5a52 17.0 landed
-
Revert: Allow table AM to store complex data structures in rd_amcache
- 922c4c461d21 17.0 landed
-
Revert: Allow table AM tuple_insert() method to return the different slot
- 8dd0bb84da7d 17.0 landed
-
Revert: Allow locking updated tuples in tuple_update() and tuple_delete()
- 193e6d18e553 17.0 landed
-
Revert: Let table AM insertion methods control index insertion
- da841aa4dc27 17.0 landed
-
Revert: Custom reloptions for table AM
- bc1e2092ebb8 17.0 landed
-
Provide a way block-level table AMs could re-use acquire_sample_rows()
- dd1f6b0c172a 17.0 landed
-
Custom reloptions for table AM
- 9bd99f4c26fe 17.0 landed
- c95c25f9af4b 17.0 landed
-
Use streaming I/O in ANALYZE.
- 041b96802efa 17.0 cited
-
Revert "Custom reloptions for table AM"
- 867cc7b6ddb9 17.0 landed
-
Let table AM insertion methods control index insertion
- b1484a3f1910 17.0 landed
-
Generalize relation analyze in table AM interface
- 27bc1772fc81 17.0 landed
-
Improve error message for tts_(virtual|minimal)_is_current_xact_tuple
- 41d3780d3d29 17.0 landed
-
Add comments on some MinimalTupleSlots methods usage
- 10baee0c95d1 17.0 landed
-
Add TupleTableSlotOps.is_current_xact_tuple() method
- 0997e0af273d 17.0 landed
-
Allow table AM tuple_insert() method to return the different slot
- c35a3fb5e067 17.0 landed
-
Allow table AM to store complex data structures in rd_amcache
- 02eb07ea89d2 17.0 landed