Draft
Conversation
…Greenplum Add support for custom scan nodes, allowing extensions to define their own scan strategies that integrate with the planner, executor, EXPLAIN, and GPDB's CDB dispatch pipeline. New node types: T_CustomScan, T_CustomScanState, T_CustomPath, T_ExtensibleNode. New files: extensible.h/c (registration framework), nodeCustom.h/c (executor callbacks). Full binary serialization support for plan dispatch to segments. Includes set_rel_pathlist_hook for planner extensibility and a test extension (custom_scan_test) that replaces SeqScan with a CustomScan to validate the pipeline end-to-end.
NJrslv
requested changes
Apr 8, 2026
Comment on lines
+102
to
+105
| if (tlistvarno == INDEX_VAR) | ||
| ExecAssignScanProjectionInfo(&css->ss); | ||
| else | ||
| ExecAssignScanProjectionInfo(&css->ss); |
Contributor
There was a problem hiding this comment.
What about two identical branches? I also don't see this code in the upstream, can you please point to the code you are porting from?
I see that upstream has different code in some places but I don't know if it's okay or not.
Contributor
Author
There was a problem hiding this comment.
It is from Postgresql code master branch
I tried to move custom nodes in gpdb because some features requires their own algorithms or path preparation logic.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Port CustomScan and ExtensibleNode infrastructure from PostgreSQL to Greenplum
custom_scan_test extension is an example how to use it and simple example to check that it works