feat: add io_uring micro-benchmark playground#406
Conversation
Adds documentdb-playground/io-uring-benchmark/, a reproducible cloud (AKS/EKS) playground that measures PostgreSQL 18 io_method=io_uring vs worker vs sync on DocumentDB using the documentdb/micro-benchmarks Locust read suite. Includes: - Three DocumentDB CR variants driven by spec.postgres.parameters.io_method. - Kyverno mutate policies (Unconfined quick-start + hardened Localhost) plus the CNPG io_uring seccomp profile and a node installer DaemonSet, since the DocumentDB CR has no seccomp field and CNPG defaults postgres to RuntimeDefault (which strips the io_uring_* syscalls and crash-loops PG18). - An in-cluster Locust runner, an 00..99 script pipeline, and analyze.py that emits a median + speedup-vs-sync summary table. - A README documenting the proven feasibility (seccomp blocker + fix, verified on kind) and the I/O-bound benchmark methodology. Depends on operator support for spec.postgres.parameters (PR documentdb#307). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: German Eichberger <geeichbe@microsoft.com>
|
🤖 Auto-triaged by documentdb-triage-tool. Applied: Reasoningcomponent from path globs (playground, docs); effort from diff stats (2067+0 LOC, 23 files); LLM: Adds a new multi-file io_uring benchmarking playground (manifests, scripts, Kyverno policies, harness, README) scoped entirely to the playground component; it's a nice-to-have experimental feature with no functional or blocking impact. If a label is wrong, remove it manually and ping |
|
Superseded by #407, which makes io_uring a first-class operator-native opt-in feature gate ( |
What
Adds
documentdb-playground/io-uring-benchmark/— a reproducible cloud (AKS/EKS) playground that measures PostgreSQL 18io_method = io_uringvsworkervssyncon DocumentDB, driving thedocumentdb/micro-benchmarksLocust read-query suite.Why / proven feasibility
A spike on a local kind cluster (kernel 6.12,
io_uring_disabled=0) established the full enable path:18-minimal-trixieships io_uringinitdbbootstrap postgres attempts io_uring queue setupRuntimeDefault→FATAL: could not setup io_uring queue: Operation not permittedUnconfined→ PG18.3 starts,SHOW io_method=io_uring,pg_stat_ioreads flowCNPG natively exposes
spec.seccompProfile, but the DocumentDB CR has no seccomp field, so the playground relaxes seccomp on the CNPG postgres pods via a Kyverno mutate policy.Contents
manifests/documentdb-{sync,worker,io_uring}.yaml— differ only inspec.postgres.parameters.io_method.Unconfinedquick-start + hardenedLocalhost), the curated CNPG io_uring profile (from CNPG #10446), and a node-installer DaemonSet.00…99script pipeline +analyze.py(median + speedup-vs-synctable).pg_stat_iocorroboration).How to run
Notes
spec.postgres.parameters(feat: add PostgreSQL parameter tuning with memory-aware defaults #307). The README's link topostgresql-tuning.mdresolves once feat: add PostgreSQL parameter tuning with memory-aware defaults #307 lands.results/.Co-authored-by: Copilot 223556219+Copilot@users.noreply.github.com