[Bug] Correct classification of plan nodes
Maintainer antworten meist innerhalb von 2 Tagen
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 2/5
- Geschätzter Aufwand
- 1-3 Stunden
- Anfängerfreundlichkeit
- 58/100
Rechercherichtung
Read is_plan_node in src/backend/cdb/cdbllize.c and inspect the node definitions in plannodes.h that determine the T_Plan_Start..T_Plan_End range. Check whether the range and the listed exceptions classify plan nodes correctly, then add or update focused tests for serialization classification. Done means non-plan nodes are excluded and actual plan nodes are recognized.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Apache Cloudberry version
main
What happened
Some nodes that are not plan nodes have been incorrectly categorized as plan nodes, while some actual plan nodes have failed to be classified as such. We need to categorize these nodes correctly; otherwise, it could lead to issues regarding the correctness of serialization. What follows may not be exhaustive.
diff --git a/src/backend/cdb/cdbllize.c b/src/backend/cdb/cdbllize.c
index 31749f0305b..b4bdf5bf863 100644
--- a/src/backend/cdb/cdbllize.c
+++ b/src/backend/cdb/cdbllize.c
@@ -1430,6 +1430,24 @@ is_plan_node(Node *node)
if (node == NULL)
return false;
+ /*
+ * Node tags are generated in the order the structs appear in
+ * plannodes.h, so the T_Plan_Start..T_Plan_End range is not exact:
+ * NestLoopParam and ExternalScanInfo are defined among the plan nodes
+ * but are not Plans, and PartitionSelector is defined after
+ * PlanRowMark but is one.
+ */
+ switch (nodeTag(node))
+ {
+ case T_NestLoopParam:
+ case T_ExternalScanInfo:
+ return false;
+ case T_PartitionSelector:
+ return true;
+ default:
+ break;
+ }
+
if (nodeTag(node) >= T_Plan_Start && nodeTag(node) < T_Plan_End)
return true;
return false;
What you think should happen instead
No response
How to reproduce
Cannot be exhaustively listed
Operating System
NAME="Rocky Linux" VERSION="9.5 (Blue Onyx)"
Anything else
No response
Are you willing to submit PR?
- Yes, I am willing to submit a PR!
Code of Conduct
- I agree to follow this project's Code of Conduct.
- Vorherrschende Sprache
- C
- Sterne
- 1.4k
- Forks
- 273
- Ø Merge
- 4 T. 6 Std.
- Gemergte PRs (30 T.)
- 105
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus apache/cloudberry
-
isolation2 lockmodes fails on cassert builds: extra AccessShareLock on partition rootEvtl. vergeben @tuhaihe hat das heute übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
apache/cloudberry#2356 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
psql tab completion broken for storage servers, tags, profiles and resource groups (pre-PG15 query format)Evtl. vergeben @allenvox hat das vor 5 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
apache/cloudberry#2316 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
[Bug] Expand fails to recognize user-defined tablespacesEvtl. vergeben @nix-oss hat das vor 92 Tagen übernommen. Offentype: Bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
apache/cloudberry#1885 · 2 Reaktionen ·
Maintainer antworten meist innerhalb von 2 Tagen
-
gpexpand first stage fails: 'SyncPackages' object has no attribute 'ret' (extension sync never runs; regression)Evtl. vergeben @talmacschen-arch hat das vor 154 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 86/100
apache/cloudberry#1825 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
type: Bug
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 53/100
apache/cloudberry#2350 · 1 Reaktion ·
Maintainer antworten meist innerhalb von 2 Tagen
Alle Issues in apache/cloudberry
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 74/100
389ds/389-ds-base#8152 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
Maintainer antworten meist innerhalb von 1 Tag
-
windows-artifacts: the win-arm64 job uses a Visual Studio generator missing from windows-11-armOffen
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 86/100
-
documentation
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 91/100
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 66/100
wasm-micro-runtime/wasm-micro-runtime#5217 ·
Maintainer antworten meist innerhalb von 3 Tagen