Plan-dumper: Add Umbra, CedarDB, MariaDB, and Trino - #164
Open
vogelsgesang wants to merge 10 commits into
Open
Conversation
I am planning to add support for additional database engines. In preparation for that, this commit adds plan dumps for Umbra, CedarDB, MariaDB, and Trino. To do so, the plan-dumper is extended to support those new databsaes.
vogelsgesang
commented
Aug 24, 2026
Preserve fixtures that the active engine build cannot regenerate, collect stable MariaDB statistics, and filter engine-specific memory, scheduler, and identifier fields alongside timing measurements.
Document engine-specific limitations, align all server connections behind explicit CLI arguments, and shorten the recursive CTE so Trino can produce an analyzed fixture.
Generate each engine into an empty staging directory so stale outputs cannot survive a run, and fail atomically when a requested mode is unavailable. Keep the sole legacy fixture as an explicit manual input and drop the obsolete TDE example.
Drop the obsolete camel-case Hyper example and keep every staged engine folder derived solely from its requested SQL plans. Remove the unused mode mapping hook left behind by Trino's former analyze fallback.
vogelsgesang
commented
Aug 24, 2026
Comment on lines
+5
to
+7
| fields change on every run even when the plan itself didn't. A hunk is dropped if every | ||
| removed line matches its added counterpart once those volatile fields are masked out; | ||
| if a line differs for any other reason, the whole line is kept as-is. |
Collaborator
Author
There was a problem hiding this comment.
Suggested change
| fields change on every run even when the plan itself didn't. A hunk is dropped if every | |
| removed line matches its added counterpart once those volatile fields are masked out; | |
| if a line differs for any other reason, the whole line is kept as-is. | |
| fields change on every run even when the plan itself didn't. Hunk which only differ on | |
| those volatile fields are dropped. If a hunk differs for any other reason, the whole line is kept as-is. |
Comment on lines
+25
to
+28
| # Postgres uses keys such as "Actual Total Time"; Hyper uses "cpu-cycles"; | ||
| # DuckDB uses "cpu_time", "operator_timing", and "latency"; MariaDB uses | ||
| # "r_total_time_ms"/"r_table_time_ms"; Umbra uses "durationUs"; and Trino uses | ||
| # "*Time", "*Cpu", and "*Wall" keys. |
Collaborator
Author
There was a problem hiding this comment.
use bullet point list:
Suggested change
| # Postgres uses keys such as "Actual Total Time"; Hyper uses "cpu-cycles"; | |
| # DuckDB uses "cpu_time", "operator_timing", and "latency"; MariaDB uses | |
| # "r_total_time_ms"/"r_table_time_ms"; Umbra uses "durationUs"; and Trino uses | |
| # "*Time", "*Cpu", and "*Wall" keys. | |
| # Volatile fields: | |
| # * Hyper: `cpu-cycles`; | |
| # * Umbra uses `durationUs`; | |
| # * Postgres: `Actual Total Time` | |
| # * DuckDB: `cpu_time`, `operator_timing`, and `latency` | |
| # * Trino: `*Time`, `*Cpu`, and `*Wall` keys | |
| # * MariaDB: `r_total_time_ms`/`r_table_time_ms` |
Comment on lines
+19
to
+32
| try: | ||
| import psycopg2 | ||
| except ImportError: | ||
| psycopg2 = None | ||
| import argparse | ||
| import re | ||
| import shutil | ||
| import os | ||
| import json | ||
| from pathlib import Path | ||
|
|
||
| setupFile = Path("./setup.sql") | ||
| queriesDir = Path("./queries") | ||
| targetDir = Path("../standalone-app/examples/") | ||
| hyper_params = { | ||
| "log_config": "" | ||
| } | ||
| try: | ||
| import pymysql | ||
| except ImportError: | ||
| pymysql = None | ||
|
|
||
| try: | ||
| import trino | ||
| except ImportError: | ||
| trino = None |
Collaborator
Author
There was a problem hiding this comment.
no need to try-import; just assume that the requirements.txt got installed
Describe the hunk-level behavior directly and list each engine's volatile runtime fields in a scan-friendly format.
vogelsgesang
commented
Aug 24, 2026
Import the declared dependencies directly so incomplete installations fail immediately instead of silently skipping configured databases.
Use uppercase snake case for module-level constants and regular expressions so the dumper follows standard Python naming conventions throughout.
Keep dialect differences in dedicated SQL files so the dumper executes setup statements verbatim instead of parsing and rewriting their DDL.
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.
I am planning to add support for additional database engines. In preparation for that, this commit adds plan dumps for Umbra, CedarDB, MariaDB, and Trino.
To do so, the plan-dumper is extended to support those new databsaes.