Skip to content

test(ci): run the integration suite against both servers on every release - #668

Closed
EVWorth wants to merge 2 commits into
mainfrom
docs/adr-reality
Closed

EVWorth wants to merge 2 commits into
mainfrom
docs/adr-reality

Conversation

@EVWorth

@EVWorth EVWorth commented Sep 12, 2026

Copy link
Copy Markdown
Owner

From the full-project review. Stacked on #667.

The suite runs on both servers now, without anyone remembering to

Every integration file takes MAS_TEST_PORT, and the release workflow runs the suite twice — MySQL 8, then MariaDB 11. Running it against MariaDB by hand is what found #658 (a lost connection after every query timeout) and JSON columns arriving as binary. Leaving that as something a person remembers to do is how the next one gets missed.

Three admin tests hardcoded 127.0.0.1:13306 in a direct connection URL while the admin service used the port under test — so with MAS_TEST_PORT set they tried to kill a thread id belonging to the other server. They build the URL from the same port now. Both suites pass on both servers.

Docs that described a test setup we do not have

ADR-009 claimed testing against MySQL 5.7, 8.0 and MariaDB 11 "simultaneously", plus SSL and SSH testing. Two containers run.

  • 5.7 is end-of-life (October 2023) and unsupported — said outright now, in the ADR and in Appendix B, which claimed "MySQL 5.7+ support only"
  • SSL configuration has no test. Named as a gap in TESTING_STRATEGY rather than implied to be covered
  • the SSH container is deleted: tunnelling is not implemented, and a profile configured for one is refused

Appendix B also claimed Rust 1.75+ (pinned at 1.95 in rust-toolchain.toml) and pnpm (the repo commits package-lock.json and CI installs from it).

ADR-004's mitigation said Monaco is 2 MB and lazy-loaded. It is 3.7 MB and it is the first thing on screen; what actually matters is which import is used — which is what it says now, after #667.

`import * as monaco from "monaco-editor"` is the `editor.main` barrel,
which carries the TypeScript, CSS, HTML and JSON *language services*.
Vite then builds and ships their web workers — ts.worker alone is 8 MB —
in a SQL client that never edits any of those languages.

Importing `editor.all` (every editor feature, no language services) plus
the SQL and MySQL contributions instead:

  dist total   17 MB  ->  5.3 MB
  monaco chunk 4.25 MB -> 3.69 MB
  workers      10.8 MB ->  352 KB (the editor worker alone)

Checked in a real browser rather than assumed: SQL still tokenises
(`keyword.sql`, `number.sql`, `identifier.sql`), two languages are
registered instead of ninety, and find, fold, suggest, uppercase and
comment-line — every action the toolbar and the shortcuts drive — are
all still there.

One test-only consequence: Monaco's clipboard contribution asks
`document.queryCommandSupported` at import time, which jsdom does not
have at all. Stubbed in the shared setup; a real browser has it.

ARCHITECTURE's technology table listed monaco-sql-languages, React Flow,
Recharts and cmdk, none of which are dependencies, and the system
diagram drew an ERD canvas, a dashboard and a command palette, none of
which exist. Replaced with what is there.
…ease

Every integration file takes MAS_TEST_PORT now, and the release workflow
runs the suite twice — MySQL 8, then MariaDB 11. Running it against
MariaDB by hand is what found #658 and the JSON-as-binary bug; leaving
that as something a person remembers to do is how the next one is missed.

Three admin tests hardcoded `127.0.0.1:13306` in a direct connection URL
while the admin service used the port under test, so with MAS_TEST_PORT
set they killed a thread id belonging to the other server. They build
the URL from the same port now.

The docs said things that were not true of the test setup:

  - ADR-009 claimed testing against MySQL 5.7, 8.0 and MariaDB 11
    "simultaneously", plus SSL and SSH testing. Two containers run. 5.7
    is end-of-life and unsupported; SSL configuration has no test, which
    is now named as a gap rather than implied to be covered; the SSH
    container is deleted, since tunnelling is not implemented and a
    profile configured for one is refused.
  - Appendix B claimed MySQL 5.7+ support, Rust 1.75+ (pinned at 1.95)
    and pnpm (the repo commits package-lock.json).
  - ADR-004's mitigation said Monaco is 2 MB and lazy-loaded. It is
    3.7 MB and is the first thing on screen; what matters is which
    import is used, which is now what it says.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant