Skip to content

Add txn-tester transaction/isolation bug-detection builders#975

Open
arcivanov wants to merge 1 commit into
MariaDB:devfrom
arcivanov:txn-tester
Open

Add txn-tester transaction/isolation bug-detection builders#975
arcivanov wants to merge 1 commit into
MariaDB:devfrom
arcivanov:txn-tester

Conversation

@arcivanov

Copy link
Copy Markdown

What

Integrates txn-tester — a single image bundling three DBMS transaction /
isolation bug-detection tools, all built from source — into the non-latent
master:

Tool Upstream
TROC tcse-iscas/Troc
Fucci Reverie4u/Fucci
APTrans Paper-code-sigmod/APTrans

It is wired exactly like the WordPress eco-test (f_wordpress): the freshly
CI-built MariaDB docker-library image is run in a pod and the tools are pointed at
it over the pod-local loopback. The tools connect to MariaDB purely via
environment variables; this adds no MariaDB build of its own.

How

  • scripts/docker-library-build.sh — retain a <image>-txntester tag on the
    amd64 image (next to the existing -wordpress tag) so the factory has the
    CI-built MariaDB to run against.
  • master-nonlatent/master.cfggetTxnTesterFactory() creates a pod, runs
    the CI-built MariaDB, then runs the three tools sequentially via podman and
    uploads their artifacts. Two builders:
    • light (amd64-rhelN-txntester, ~6–7 min) — fast per-build signal;
    • soak (amd64-rhelN-txntester-soak, ~30 min) — deep coverage, opt-in.
  • f_dockerlibrary triggers the light builder on every saved-package build,
    and the soak builder instead on txn-prefixed branches (isTxnTesterBranch),
    mirroring the not/is-branch split used for Jepsen.
  • constants.py / schedulers_definition.pyBUILDERS_TXN_TESTER[_SOAK]
    and s_txn_tester[_soak].

Bug signalling

The upstream tools never exit non-zero on a finding (TROC/Fucci loop until killed
by timeout and only log a BUG REPORT; APTrans only writes a check/ artifact
then exits 0). The image therefore maps a discovered inconsistency to the exotic
exit code 100, and the steps use decodeRC={0: SUCCESS, 100: FAILURE} so a
found transaction anomaly turns the build red and is distinguishable from an
infrastructural failure (image pull / classpath / connection), which keep their
own non-zero codes.

Image

Pulled from ghcr.io/arcivanov/txn-tester:0.0.2 (--pull=always), pinned for
reproducibility. It lives in its own repo for now; if MariaDB adopts it, only the
image reference changes (optionally adding an in-tree eco_build_images build).

Notes

  • Validated with ./validate_master_cfg.sh -e DEV — all master configs check out.
  • Heads-up: in local/CI testing, TROC and Fucci both report inconsistencies
    against stock MariaDB within a short run, so these builders will go red fairly
    often. That is the intended finding→red→triage behaviour; whether the reports
    are true anomalies or tool noise is worth review before treating red/green as a
    clean pass/fail signal.

Integrate txn-tester (TROC, Fucci and APTrans bundled in a single image) into the
non-latent master, modelled on the WordPress eco-test wiring: run the freshly
CI-built MariaDB docker-library image in a pod and point the tools at it over the
pod-local loopback.

- docker-library-build.sh: retain a "<image>-txntester" tag on the amd64 image
  (alongside "-wordpress") so the factory has the CI-built MariaDB to run against.
- master-nonlatent: getTxnTesterFactory() runs the three tools sequentially via
  podman against the pod-local MariaDB and uploads their artifacts. Two builders
  are added: a light per-build profile (~6-7 min) and a soak profile (~30 min).
- The tools never exit non-zero on a finding, so the image maps a discovered
  inconsistency to the exotic exit code 100; decodeRC={0:SUCCESS,100:FAILURE}
  turns a found transaction anomaly red, distinct from infrastructural failures
  (image pull / classpath / connection), which keep their own codes.
- f_dockerlibrary triggers the light builder on every saved-package build and the
  soak builder instead on "txn"-prefixed branches (isTxnTesterBranch), mirroring
  the not-/is-branch split used for Jepsen.
- constants/schedulers: BUILDERS_TXN_TESTER[_SOAK] + s_txn_tester[_soak].

Image: ghcr.io/arcivanov/txn-tester:0.0.2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant