Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Performance

FerroEHR’s performance figures come from the same instrument as its conformance record: the perf command of Veredictum, at the release pinned in scripts/lib/veredictum.sh. A performance record earns no class and enters no conformance verdict. No openEHR specification governs performance, so the measurement method is Veredictum’s own design, described in its book under Measured performance. Nothing on this page is hand-typed: every number comes from the committed record or from charts drawn from it.

What a run measures

veredictum perf offers one pinned workload to a running FerroEHR as an open-loop schedule of Poisson arrivals. Each request’s latency counts from the instant it was due, not from when it was sent, so a server that stalls cannot hide the queue it builds behind a few fast replies. A run has these phases:

  1. Seeding, before the clock: the workload’s corpus is committed through the public write path, closed-loop, and reported apart.
  2. Posture canaries: a first bracket of probes checks that the deployment runs the posture the run declares (below).
  3. Settle: vacuumdb --all --analyze runs in the database container, so no plateau pays the seed’s maintenance debt.
  4. Warm-up, discarded.
  5. Scout: an exponential ramp, judged in short windows, whose first breach gives an estimate of the knee.
  6. Ladder: plateaus at fixed fractions of that estimate, each held long enough to judge its tail.
  7. Closing: the second bracket of posture canaries.

The whole run after seeding takes at most ten minutes. A plateau qualifies when every operation keeps its judged percentile inside its latency budget, the errors stay inside the error budget, the achieved rate keeps up with the offered rate, and the load generator kept up. One 429 voids the record.

How to read the record

The record is a perf-result document, docs/conformance/ferroehr/perf-result.json:

  • The knee is the highest offered rate whose plateau qualifies with every plateau below it. It is a bracket between that plateau and the first one that fails, a lower bound when every plateau qualifies, or below the ladder.
  • The peak is the highest achieved throughput, whatever its latency.
  • Percentiles p50 to p99.9 per operation come from the recorded histograms with their confidence intervals. A percentile with too few samples above it reads n/r, not resolvable, and each operation is judged at the highest percentile that resolves.
  • Population turns the knee into the range of people a deployment of that capacity serves at its peak, beside the corpus scale it was measured at.
  • Server-side readings (CPU, memory and I/O per container, database sizes, the top pg_stat_statements entries, the PostgreSQL settings) are context for capacity planning and never enter a judgement.
  • Between-run noise reads unmeasured unless an A/A floor is attached (below).

veredictum perf-judge re-derives every derived number from the recorded histograms and fails when one byte differs, so the record can be checked by anyone who has it.

The workload

The published record offers clinical-mix, Veredictum’s reference workload: what a clinical front end sends, with chart review as short sessions on one EHR, ward boards, problem lists, cohort counts, AQL over ad-hoc and stored queries, and the order, result, correction, folder, tag, definition, demographic and bootstrap traffic around them. Every share in the mix names its derivation, and the payloads are published openEHR CKM templates. The pinned workloads, their expanded per-operation mix and their digests are listed on Veredictum’s Performance workloads page.

The measured posture

A latency figure is a claim about a configuration, so the run declares one and its canaries check it before and after the measured window. FerroEHR is measured as minimal-signed-digest: commits validated against the operational template and every version digest-signed, which is how FerroEHR ships. The measurement overlay docker/sut-measurement.yml changes two things against the conformance deployment, both visible in the file: it switches per-caller rate limiting off, because the scout ramp offers load past the knee from one caller on purpose, and it switches response compression off, because every posture profile declares it off and a compressed answer would refuse the run.

The durability floor: what a single write can never beat

Every committed version is durable: the transaction’s WAL records are flushed to disk before the server answers, so an acknowledged commit survives a crash. That flush (one fsync on the WAL device per commit) is a physical lower bound on single-client write latency, and no storage design takes a lone sequential client below it. On a laptop-class Docker setup the flush alone dominates a single write’s budget; on server NVMe it is typically an order of magnitude smaller. FerroEHR’s optimization target is therefore everything around the flush: the database’s own per-commit work (one folded commit statement, one merged placement read) stays far below the flush itself. That is also what makes concurrent throughput scale: PostgreSQL group-commits, amortizing one flush across every transaction that reaches it in the same window.

The knob behind this boundary is PostgreSQL’s synchronous_commit. Setting it off makes commits return before the WAL flush: single-client write latency drops to the statement work alone, and a server crash can lose the most recent acknowledged commits (up to three times wal_writer_delay, per the PostgreSQL documentation). The database stays consistent; the tail of acknowledged writes is what is at risk. FerroEHR never defaults this off and does not recommend it for clinical data. It is an operator decision, made per deployment on the database side, defensible only where the record of loss is acceptable (a load-test rig, a reseedable sandbox, an analytics replica). All published FerroEHR numbers are measured with full durability on.

Reproducing it

The measured lane is a stage of the conformance pipeline. It composes the conformance deployment with the measurement overlay on fresh volumes, runs veredictum perf, re-derives the record with perf-judge, and redraws the charts on this page:

bash scripts/conformance.sh perf

# the same deployment measured against itself, interleaved, so the record
# carries its between-run noise floor
bash scripts/conformance.sh perf-aa

CONF_PERF_WORKLOAD picks another pinned workload (aql-mix offers the six AQL classes alone), CONF_PERF_POSTURE another posture profile, and CONF_PERF_OUT another record path. The stage runs the pinned binary on the host, because the settle phase reaches the database container with docker exec; the IXIT’s containers block names the containers. To measure a deployment the pipeline does not compose, drive the instrument directly:

source scripts/lib/veredictum.sh
"$(veredictum_bin)" perf --root "$(veredictum_perf)" \
  --catalogue "$(veredictum_catalogue)" \
  --ixit docs/conformance/party/ferroehr/ixit.json \
  --statement docs/conformance/party/ferroehr/statement.json \
  --workload "$(veredictum_workload clinical-mix)" \
  --posture minimal-signed-digest \
  --host-prescription reference-8cpu-8gb \
  --out perf-result.json
"$(veredictum_bin)" perf-judge --result perf-result.json

scripts/render/perf-assets.sh draws the charts and the summary from the committed record with veredictum perf-assets, and the docs CI job re-renders and diffs them, so a hand-edited or stale chart fails the build.

Where a published figure is measured

Two hosted runs of the same code can read far apart, so an absolute figure from a shared CI runner says little. A published record is measured on the idle reference host and names it with a host prescription (reference-8cpu-8gb, under perf/ in Veredictum); the record reads the prescription against the fingerprint the load generator measured, and a host that does not match reads unmatched with every difference. On any other machine, compare two builds instead: veredictum perf-compare --ab runs both sides interleaved on one host from one seed, and a difference counts only when it clears the tolerance and the A/A floor.

The storage benchmark harness

A second instrument measures the storage layer directly, below the wire:

STORAGE_BENCH_CLASS=poc cargo bench -p ferroehr --bench storage

It seeds a corpus through the ordinary write path, then times the storage layer’s hot paths one at a time: a composition commit, a supersession, the supersession that states the version it replaces, a point read by version uid and one by versioned-object uid, the version at an instant, the revision history, an AQL CONTAINS chain over one EHR and over the whole population, archive and restore of an EHR, and one retention prune.

Beside each operation’s wall-clock it records what the database did for it. The per-relation tuple counters (inserted, updated, updated in place, dead, live) and the relation sizes come from pg_stat_user_tables, the buffer hits and misses from pg_stat_database, and the write-ahead-log bytes from the WAL position either side of the measurement. One representative commit is probed on its own, and the population query is explained with EXPLAIN (ANALYZE, BUFFERS, WAL) inside a transaction that is rolled back, so the plan shape and its index choices land in the record too.

Everything runs through the service and the public storage API, and the relations are discovered from the catalogue, so no table name appears anywhere in the harness and the same file measures a rewritten schema. That is the point: a storage change is argued from a before-and-after pair taken with one instrument. It earns no class and touches no conformance artifact; the record’s shape is documented in docs/benchmarks/storage/README.md. Records are local by default, and the committed baseline is what this page renders.

Comparing two builds on one runner

A dispatch-only workflow (.github/workflows/storage-bench.yml) runs the same benchmark on one GitHub-hosted runner, against a PostgreSQL 18 service with its durability left on, for two builds: a baseline and a candidate. The candidate is the dispatched ref, and the baseline is its merge base with main unless the dispatch names another revision, so a dispatch on main measures the same code twice and shows the lane’s own noise. The two builds run in turn, several rounds each (eight by default), in alternating order, and each round seeds a fresh database and runs ANALYZE before it measures anything. A runner that slows down part way through then slows both builds alike.

Both builds are measured on the same machine because a latency compared with a record from another runner says little: two hosted runs of the same bench code read 20 of 27 operations 40 to 156 % apart. Two verdicts come out of the rounds, and either one fails the run:

  • The plan verdict reads pages per call, the buffer hits and reads per call, which do not depend on the speed of the machine. An operation fails when the candidate’s median rose more than the page tolerance (10 % by default), and by at least one page, above the highest baseline round.
  • The time verdict first divides each round by its machine factor, so a round where the whole runner ran slow does not read as the code. An operation regresses only when its median p50 or p99 rose more than the tolerance (15 % by default) and every candidate round is slower than every baseline round at that percentile. A rise whose rounds overlap the baseline’s is reported as within the noise of the rounds.

The candidate’s storage sizes do not depend on the machine, so they are judged against the record committed for its schema generation and class: bytes per composition version or per node row that grew more than the size budget (5 % by default) fail the run. A generation and class with no committed record fails the run, with the error in the job summary, so the change that moves the schema generation commits the new generation’s records with it (#4291). The run summary lists every round with its machine factor, and each operation with its pages per call and its raw and adjusted change.

That lane is exploration, never a conformance record. It earns no performance class, publishes no number, and writes nothing back to the repository: the round records leave as a run artifact, and the committed baseline under docs/benchmarks/storage/<generation>/ moves only in a pull request that says which run measured it. docs/benchmarks/storage/README.md records the numbers behind each bound (#4318).

Schema generation generation-1, class s

OperationIterationsp50p95p99WALBuffer hits
create_first_version1 2003.6 ms5.3 ms5.3 ms47 MiB1 008 028
supersede87011.2 ms14.4 ms14.4 ms37.5 MiB30 795 283
supersede_if_match85011.4 ms14.5 ms14.5 ms36.5 MiB29 699 039
by_version_uid13 640298.6 µs374.6 µs374.6 µs77.3 KiB250 604
latest_by_versioned_object_uid8 550479.9 µs1 ms1 ms456 B121 845
version_at_time7 260597.3 µs640 µs640 µs136 B122 318
revision_history25 230193.9 µs216.6 µs216.6 µs88 B671 513
contains_one_ehr2 8501.7 ms1.8 ms1.8 ms368 B766 648
contains_population3 4401.1 ms1.1 ms1.1 ms0 B1 294 649
archive_ehr9023.3 ms30.3 ms30.3 ms252.7 MiB6 969 118
restore_ehr16024.9 ms69.1 ms69.1 ms400.5 MiB9 276 746
retention_prune25 650166.7 µs185.7 µs185.7 µs104 B35 104

One representative commit wrote 2.6 MiB of WAL and touched 88 172 buffers. The population CONTAINS statement plans as Gather and reads 55 817 shared blocks.

RelationLive rowsDead rowsUpdatesHOT updatesSize
ehr.audit7 1880001.9 MiB
ehr.contribution6 9880001.3 MiB
ehr.ehr100000112 KiB
ehr.event_outbox6 9880003.9 MiB
ehr.node296 059000271.8 MiB
ehr.template_ref100032 KiB
ehr.template_store1000136 KiB
ehr.vo_archive000040 KiB
ehr.vo_version7 08802 330030.1 MiB

Measured over 100 EHRs and 3 000 compositions of template Vital signs at commit 6ebfdb32b304 on 8 cores against PostgreSQL 18.6.

Schema generation generation-2, class poc

OperationIterationsp50p95p99WALBuffer hits
create_first_version5308.5 ms9.1 ms9.1 ms24.2 MiB395 240
supersede47010.3 ms11.1 ms11.1 ms21.6 MiB905 767
supersede_if_match54010 ms11.2 ms11.2 ms24.1 MiB1 070 922
by_version_uid8 290519.5 µs538.3 µs538.3 µs168 B213 581
latest_by_versioned_object_uid8 630534.3 µs553.9 µs553.9 µs120 B204 101
version_at_time4 290990.6 µs996 µs996 µs0 B135 299
revision_history15 730300.1 µs312.9 µs312.9 µs0 B437 101
contains_one_ehr1 1404 ms4.2 ms4.2 ms128 B605 955
contains_population2 2702.1 ms2.2 ms2.2 ms0 B620 677
flat_2_sibling_leaves21021.9 ms22.7 ms22.7 ms112 B3 639 915
flat_3_sibling_leaves19025.5 ms26.7 ms26.7 ms88 B3 422 117
streaming_2_sibling_leaves8705.9 ms6.2 ms6.2 ms0 B2 524 699
streaming_3_sibling_leaves8006.2 ms6.3 ms6.3 ms0 B2 580 569
contains_exists5808.4 ms8.5 ms8.5 ms0 B6 860 724
node_predicate1 2404 ms4.2 ms4.2 ms0 B2 130 540
where_magnitude11046.4 ms47.3 ms47.3 ms0 B3 399 817
where_coded20023.4 ms25.8 ms25.8 ms0 B3 495 572
where_date_time1 0704.5 ms4.6 ms4.6 ms0 B1 884 349
where_text21023.2 ms24.4 ms24.4 ms0 B3 628 755
wide_projection_one_ehr10053.2 ms55.3 ms55.3 ms56 B464 725
wide_projection_population18029.2 ms32.9 ms32.9 ms0 B3 761 922
select_observation7606.5 ms6.8 ms6.8 ms0 B1 804 991
select_composition_one_ehr8605.5 ms6.7 ms6.7 ms0 B474 289
aql_version_at_time1 2204 ms4.2 ms4.2 ms0 B1 827 733
archive_ehr3091.4 ms101.2 ms101.2 ms52.9 MiB1 038 199
restore_ehr30106.1 ms108.4 ms108.4 ms52.7 MiB1 121 364
retention_prune23 420211.1 µs236.3 µs236.3 µs8.3 KiB33 082

One representative commit wrote 305 KiB of WAL and touched 3 903 buffers. The population CONTAINS statement plans as Nested Loop and reads 43 224 shared blocks.

RelationLive rowsDead rowsUpdatesHOT updatesSize
clinical.commit_audit2 324000632 KiB
clinical.contribution2 284000584 KiB
clinical.ehr2000056 KiB
clinical.event_outbox2 2840001.4 MiB
clinical.node_cold000088 KiB
clinical.node_hot100 33200081.4 MiB
clinical.template_ref200032 KiB
clinical.template_store2000192 KiB
clinical.version_cold0000120 KiB
clinical.version_hot2 3040008.8 MiB
clinical.vo_head1 020603 9483 948312 KiB

Measured over 20 EHRs and 300 compositions of template Vital signs at commit c82f0992d308 on 4 cores against PostgreSQL 18.6.

Schema generation generation-2, class s

OperationIterationsp50p95p99WALBuffer hits
create_first_version5109.7 ms9.9 ms9.9 ms110.9 MiB470 378
supersede5009.9 ms10.4 ms10.4 ms22.8 MiB1 034 920
supersede_if_match54010 ms10.4 ms10.4 ms24.4 MiB1 151 542
by_version_uid8 700488.6 µs493.7 µs493.7 µs2.8 KiB222 174
latest_by_versioned_object_uid9 360489.2 µs512.2 µs512.2 µs128 B218 149
version_at_time4 490946.8 µs992.3 µs992.3 µs56 B146 116
revision_history16 450287.8 µs300.8 µs300.8 µs0 B453 104
contains_one_ehr1 2403.6 ms3.7 ms3.7 ms136 B658 178
contains_population1 7403 ms3 ms3 ms0 B1 020 037
flat_2_sibling_leaves6092.3 ms95.9 ms95.9 ms16.4 KiB33 018 094
flat_3_sibling_leaves6095.9 ms97.8 ms97.8 ms0 B33 030 979
streaming_2_sibling_leaves6607.6 ms7.9 ms7.9 ms0 B2 398 276
streaming_3_sibling_leaves6308 ms8.1 ms8.1 ms0 B2 137 922
contains_exists17030.2 ms34.2 ms34.2 ms0 B11 007 303
node_predicate9305.4 ms5.5 ms5.5 ms0 B2 127 292
where_magnitude50120.1 ms121.4 ms121.4 ms0 B5 504 663
where_coded7206.9 ms7.2 ms7.2 ms0 B2 269 954
where_date_time8206.1 ms6.2 ms6.2 ms0 B1 917 884
where_text7306.9 ms7 ms7 ms0 B2 293 234
wide_projection_one_ehr50114.2 ms115.6 ms115.6 ms0 B1 977 924
wide_projection_population38013.3 ms13.7 ms13.7 ms88 B2 326 270
select_observation6207.9 ms8 ms8 ms0 B1 607 057
select_composition_one_ehr6008.2 ms8.5 ms8.5 ms0 B683 661
aql_version_at_time8006.2 ms6.3 ms6.3 ms0 B6 498 839
archive_ehr20173 ms181.1 ms181.1 ms68 MiB1 320 254
restore_ehr20204.5 ms207.9 ms207.9 ms60.6 MiB1 298 376
retention_prune23 980207.7 µs209 µs209 µs2.1 MiB73 258

One representative commit wrote 297.2 KiB of WAL and touched 960 buffers. The population CONTAINS statement plans as Nested Loop and reads 42 257 shared blocks.

RelationLive rowsDead rowsUpdatesHOT updatesSize
clinical.commit_audit5 4860001.5 MiB
clinical.contribution5 286000960 KiB
clinical.ehr100000152 KiB
clinical.event_outbox5 2860002.9 MiB
clinical.node_cold0000232 KiB
clinical.node_hot252 462000167.6 MiB
clinical.template_ref200032 KiB
clinical.template_store2000192 KiB
clinical.version_cold0000144 KiB
clinical.version_hot5 3347820016.3 MiB
clinical.vo_head3 940134 4304 430936 KiB

Measured over 100 EHRs and 3 000 compositions of template Vital signs at commit c82f0992d308 on 4 cores against PostgreSQL 18.6.

Schema generation generation-3, class poc

OperationIterationsp50p95p99WALBuffer hits
create_first_version8405.8 ms14.6 ms14.6 ms34.8 MiB648 612
supersede61011.4 ms18.9 ms18.9 ms23 MiB13 048 343
supersede_if_match64012.3 ms21.6 ms21.6 ms28 MiB19 143 656
by_version_uid9 920418.8 µs439.7 µs439.7 µs472 B245 293
latest_by_versioned_object_uid11 710404.2 µs428.5 µs428.5 µs0 B301 532
version_at_time4 940874.4 µs886.1 µs886.1 µs0 B151 435
revision_history18 710206.6 µs248.5 µs248.5 µs0 B502 662
contains_one_ehr1 4103.5 ms3.6 ms3.6 ms7 KiB859 578
contains_population2 6901.8 ms1.9 ms1.9 ms8.1 KiB824 801
flat_2_sibling_leaves23019.4 ms20 ms20 ms42.4 KiB5 239 470
flat_3_sibling_leaves21023.4 ms23.8 ms23.8 ms0 B4 934 788
streaming_2_sibling_leaves9805.1 ms5.3 ms5.3 ms3.6 KiB2 960 620
streaming_3_sibling_leaves9005.5 ms5.7 ms5.7 ms0 B3 007 660
contains_exists47010.5 ms11.1 ms11.1 ms0 B8 638 704
node_predicate1 3803.6 ms3.7 ms3.7 ms0 B2 969 000
where_magnitude11047.7 ms48.7 ms48.7 ms0 B5 012 010
where_coded23022.1 ms23.1 ms23.1 ms0 B5 209 927
where_date_time1 2104.1 ms4.2 ms4.2 ms0 B2 292 883
where_text23022.4 ms23.3 ms23.3 ms0 B5 210 914
wide_projection_one_ehr12042.1 ms42.9 ms42.9 ms0 B526 091
wide_projection_population19027.3 ms28.6 ms28.6 ms0 B5 064 088
select_observation8505.7 ms5.8 ms5.8 ms0 B2 121 054
select_composition_one_ehr9904.8 ms5 ms5 ms0 B551 999
aql_version_at_time1 4503.4 ms3.6 ms3.6 ms0 B2 565 200
archive_ehr5051.3 ms54.2 ms54.2 ms87.7 MiB1 896 225
restore_ehr5064.2 ms65.2 ms65.2 ms77.1 MiB1 945 710
retention_prune40 630118.4 µs121.5 µs121.5 µs120 B50 499

One representative commit wrote 532.7 KiB of WAL and touched 1 322 buffers. The population CONTAINS statement plans as Nested Loop and reads 17 067 shared blocks.

RelationLive rowsDead rowsUpdatesHOT updatesSize
clinical.commit_audit3 130000872 KiB
clinical.contribution3 090000640 KiB
clinical.ehr2000064 KiB
clinical.event_outbox3 0900001.8 MiB
clinical.node_cold000088 KiB
clinical.node_hot134 99000089.3 MiB
clinical.template_ref200032 KiB
clinical.template_store2000192 KiB
clinical.version_cold0000136 KiB
clinical.version_hot3 11000012.7 MiB
clinical.vo_head1 458486 3326 332504 KiB

Measured over 20 EHRs and 300 compositions of template Vital signs at commit 59b91af928a4 on 4 cores against PostgreSQL 18.6.

Schema generation generation-3, class s

OperationIterationsp50p95p99WALBuffer hits
create_first_version5607.6 ms8.6 ms8.6 ms21.6 MiB475 947
supersede52012.9 ms16.4 ms16.4 ms21.6 MiB10 171 802
supersede_if_match52013 ms16.7 ms16.7 ms20.1 MiB9 750 360
by_version_uid9 210480 µs495 µs495 µs2.2 KiB226 321
latest_by_versioned_object_uid9 340477.9 µs486.9 µs486.9 µs464 B224 344
version_at_time4 510943.2 µs1 ms1 ms0 B140 807
revision_history17 290268.1 µs271.6 µs271.6 µs0 B471 470
contains_one_ehr1 2503.6 ms3.9 ms3.9 ms0 B695 743
contains_population1 6803 ms3.1 ms3.1 ms15.8 KiB1 115 539
flat_2_sibling_leaves14033.9 ms38.2 ms38.2 ms16.2 KiB4 120 479
flat_3_sibling_leaves14037.9 ms39 ms39 ms232 B4 152 775
streaming_2_sibling_leaves5808.5 ms9.3 ms9.3 ms0 B2 007 543
streaming_3_sibling_leaves5808.7 ms8.8 ms8.8 ms0 B2 152 855
contains_exists20025.6 ms26.5 ms26.5 ms0 B9 295 830
node_predicate8306 ms6.1 ms6.1 ms0 B2 174 425
where_magnitude50105.2 ms106 ms106 ms0 B4 729 616
where_coded7806.2 ms6.6 ms6.6 ms0 B1 888 942
where_date_time7506.8 ms7.1 ms7.1 ms0 B2 001 044
where_text8106.2 ms6.3 ms6.3 ms0 B1 943 864
wide_projection_one_ehr50110 ms111.3 ms111.3 ms0 B1 950 208
wide_projection_population41012.4 ms12.5 ms12.5 ms0 B2 101 466
select_observation5608.7 ms9 ms9 ms0 B1 619 828
select_composition_one_ehr6008.4 ms8.7 ms8.7 ms0 B685 119
aql_version_at_time7106.4 ms7.2 ms7.2 ms0 B5 900 107
archive_ehr20138.1 ms141 ms141 ms65.3 MiB1 558 971
restore_ehr20170.1 ms173.7 ms173.7 ms59.2 MiB1 516 172
retention_prune27 760177.4 µs180.1 µs180.1 µs1.2 MiB71 274

One representative commit wrote 107.4 KiB of WAL and touched 3 784 buffers. The population CONTAINS statement plans as Nested Loop and reads 49 471 shared blocks.

RelationLive rowsDead rowsUpdatesHOT updatesSize
clinical.commit_audit5 4840001.5 MiB
clinical.contribution5 2840001.1 MiB
clinical.ehr10000096 KiB
clinical.event_outbox5 2840003 MiB
clinical.node_cold0000232 KiB
clinical.node_hot254 612000114.1 MiB
clinical.template_ref200032 KiB
clinical.template_store2000192 KiB
clinical.version_cold0000160 KiB
clinical.version_hot5 38400018.1 MiB
clinical.vo_head3 9901044 9584 958968 KiB

Measured over 100 EHRs and 3 000 compositions of template Vital signs at commit 59b91af928a4 on 4 cores against PostgreSQL 18.6.

Schema generation generation-4, class poc

OperationIterationsp50p95p99WALBuffer hits
create_first_version1 0804.4 ms4.5 ms4.5 ms38.6 MiB839 369
supersede8306.4 ms6.8 ms6.8 ms30.3 MiB1 881 701
supersede_if_match9106.4 ms11.6 ms11.6 ms33 MiB2 185 823
by_version_uid8 220536.8 µs572.1 µs572.1 µs760 B152 667
latest_by_versioned_object_uid8 640531.8 µs556.7 µs556.7 µs128 B151 163
version_at_time4 2701 ms1.2 ms1.2 ms0 B92 326
revision_history18 100257.8 µs268.3 µs268.3 µs0 B289 666
contains_one_ehr7106.8 ms7 ms7 ms0 B2 827 280
contains_population2 1502.3 ms2.3 ms2.3 ms144 B555 234
flat_2_sibling_leaves27017.6 ms19.5 ms19.5 ms0 B988 291
flat_3_sibling_leaves22022.9 ms23 ms23 ms88 B895 288
streaming_2_sibling_leaves6807.4 ms7.5 ms7.5 ms0 B2 359 238
streaming_3_sibling_leaves6307.9 ms8 ms8 ms0 B2 416 209
contains_exists36013.3 ms13.9 ms13.9 ms0 B6 013 262
node_predicate9905.1 ms5.2 ms5.2 ms0 B2 103 028
where_magnitude7074.6 ms75.8 ms75.8 ms0 B3 771 071
where_coded8405.9 ms6 ms6 ms0 B1 896 739
where_date_time8605.8 ms6 ms6 ms0 B1 871 050
where_text8206.1 ms6.3 ms6.3 ms0 B1 965 435
wide_projection_one_ehr12041.7 ms43 ms43 ms0 B130 689
wide_projection_population40012.4 ms12.8 ms12.8 ms0 B2 007 008
select_observation6807.4 ms7.6 ms7.6 ms0 B1 857 760
select_composition_one_ehr8705.7 ms6.1 ms6.1 ms0 B705 797
person_identifier_lookup8805.5 ms5.7 ms5.7 ms0 B84 973
ehr_by_subject11 030443.9 µs466.6 µs466.6 µs0 B15 268
aql_version_at_time1 2404 ms4.1 ms4.1 ms0 B1 710 369
archive_ehr4058.2 ms68.1 ms68.1 ms52.2 MiB1 624 838
restore_ehr4082.9 ms89.1 ms89.1 ms47.2 MiB1 378 980
retention_prune33 890141.1 µs142.2 µs142.2 µs4.2 KiB43 579

One representative commit wrote 304.6 KiB of WAL and touched 1 047 buffers. The population CONTAINS statement plans as Hash Join and reads 14 350 shared blocks.

RelationLive rowsDead rowsUpdatesHOT updatesSize
clinical.commit_audit4 0180001.1 MiB
clinical.contribution3 978000832 KiB
clinical.ehr2000064 KiB
clinical.event_outbox3 9780002.2 MiB
clinical.node_cold0000152 KiB
clinical.node_hot171 88400061.2 MiB
clinical.template_ref200032 KiB
clinical.template_store2000192 KiB
clinical.version_cold0000160 KiB
clinical.version_hot3 96800012.5 MiB
clinical.vo_head1 6982435 6545 654680 KiB

Measured over 20 EHRs and 300 compositions of template Vital signs at commit 40bb79e3a10f on 4 cores against PostgreSQL 18.6.

Schema generation generation-4, class s

OperationIterationsp50p95p99WALBuffer hits
create_first_version1 0904.3 ms4.5 ms4.5 ms38.1 MiB944 061
supersede8805.9 ms6.7 ms6.7 ms31.7 MiB2 069 808
supersede_if_match9006 ms6.7 ms6.7 ms32.4 MiB2 146 906
by_version_uid9 080464.6 µs472.7 µs472.7 µs416 B166 080
latest_by_versioned_object_uid9 050464.5 µs477.4 µs477.4 µs0 B156 894
version_at_time4 370962.6 µs977.3 µs977.3 µs0 B94 361
revision_history18 030240.8 µs283.7 µs283.7 µs0 B288 746
contains_one_ehr1 1903.8 ms4 ms4 ms0 B389 580
contains_population1 8402.7 ms2.9 ms2.9 ms0 B1 258 017
flat_2_sibling_leaves20024.9 ms27.7 ms27.7 ms31 KiB1 551 924
flat_3_sibling_leaves16031.7 ms32.7 ms32.7 ms0 B1 381 601
streaming_2_sibling_leaves6507.6 ms8.2 ms8.2 ms0 B2 562 363
streaming_3_sibling_leaves6208.1 ms8.4 ms8.4 ms0 B2 265 330
contains_exists21024 ms24.6 ms24.6 ms0 B10 171 573
node_predicate9205.5 ms5.5 ms5.5 ms0 B2 380 645
where_magnitude50106.4 ms107.3 ms107.3 ms0 B5 916 560
where_coded9305.4 ms5.5 ms5.5 ms0 B2 027 603
where_date_time8306 ms6.2 ms6.2 ms0 B2 199 493
where_text6208.1 ms8.3 ms8.3 ms56 B3 252 641
wide_projection_one_ehr13040.8 ms41.4 ms41.4 ms0 B225 187
wide_projection_population42011.8 ms11.9 ms11.9 ms0 B2 096 692
select_observation6307.6 ms7.9 ms7.9 ms0 B1 764 369
select_composition_one_ehr5609 ms9.1 ms9.1 ms0 B611 639
person_identifier_lookup8805.4 ms5.6 ms5.6 ms0 B89 721
ehr_by_subject11 440436.2 µs451 µs451 µs0 B31 225
aql_version_at_time1 2004.2 ms4.4 ms4.4 ms0 B1 686 531
archive_ehr20126.8 ms131.6 ms131.6 ms59.9 MiB1 526 852
restore_ehr20156.7 ms158.5 ms158.5 ms55.3 MiB1 560 724
retention_prune35 910129.6 µs139.6 µs139.6 µs13.8 KiB45 727

One representative commit wrote 505.9 KiB of WAL and touched 1 274 buffers. The population CONTAINS statement plans as Hash Join and reads 14 258 shared blocks.

RelationLive rowsDead rowsUpdatesHOT updatesSize
clinical.commit_audit7 1380001.9 MiB
clinical.contribution6 9380001.4 MiB
clinical.ehr100000232 KiB
clinical.event_outbox6 9380003.9 MiB
clinical.node_cold0000128 KiB
clinical.node_hot325 734000118.4 MiB
clinical.template_ref200032 KiB
clinical.template_store2000192 KiB
clinical.version_cold0000176 KiB
clinical.version_hot7 03800024.3 MiB
clinical.vo_head4 648405 9545 9541 MiB

Measured over 100 EHRs and 3 000 compositions of template Vital signs at commit 40bb79e3a10f on 4 cores against PostgreSQL 18.6.

Schema generation generation-5, class poc

OperationIterationsp50p95p99WALBuffer hits
create_first_version9305 ms6.2 ms6.2 ms31.8 MiB730 000
supersede8107 ms7.9 ms7.9 ms28.1 MiB1 796 592
supersede_if_match7407.3 ms8.2 ms8.2 ms26.3 MiB1 672 155
by_version_uid7 980577.4 µs586.7 µs586.7 µs120 B143 712
latest_by_versioned_object_uid7 800569.2 µs584.5 µs584.5 µs632 B146 803
version_at_time4 0601.1 ms1.1 ms1.1 ms0 B98 940
revision_history14 000342 µs355.6 µs355.6 µs0 B236 366
contains_one_ehr6207.7 ms7.8 ms7.8 ms0 B1 976 026
contains_population2 0402.4 ms2.5 ms2.5 ms0 B527 159
flat_2_sibling_leaves26018.4 ms20.6 ms20.6 ms0 B946 308
flat_3_sibling_leaves19027.6 ms28.3 ms28.3 ms0 B790 531
streaming_2_sibling_leaves6008.5 ms8.6 ms8.6 ms0 B1 771 139
streaming_3_sibling_leaves5708.9 ms9.1 ms9.1 ms0 B1 840 239
contains_exists34014.7 ms15 ms15 ms0 B5 232 561
node_predicate8406 ms6.3 ms6.3 ms0 B1 771 917
where_magnitude7074.1 ms80.7 ms80.7 ms0 B3 372 688
where_coded7406.8 ms7.6 ms7.6 ms0 B1 773 273
where_date_time7506.6 ms6.8 ms6.8 ms0 B1 359 947
where_text7107.2 ms7.6 ms7.6 ms0 B1 755 614
wide_projection_one_ehr13040.6 ms40.7 ms40.7 ms0 B140 801
wide_projection_population36013.9 ms14 ms14 ms0 B1 890 224
select_observation5508.7 ms8.9 ms8.9 ms0 B1 294 608
select_composition_one_ehr7106.8 ms7.5 ms7.5 ms0 B607 419
person_identifier_lookup8605.6 ms5.6 ms5.6 ms0 B77 072
ehr_by_subject10 470468.1 µs502.4 µs502.4 µs0 B14 826
aql_version_at_time1 1404.4 ms4.5 ms4.5 ms0 B1 598 735
archive_ehr4066.2 ms77.8 ms77.8 ms50 MiB1 639 004
restore_ehr3094.5 ms100 ms100 ms35.5 MiB1 082 226
retention_prune17 970262.8 µs279.4 µs279.4 µs706.8 KiB196 365

One representative commit wrote 325.2 KiB of WAL and touched 3 962 buffers. The population CONTAINS statement plans as Hash Join and reads 18 304 shared blocks.

RelationLive rowsDead rowsUpdatesHOT updatesSize
clinical.commit_audit3 648000992 KiB
clinical.contribution3 608000784 KiB
clinical.ehr2000064 KiB
clinical.event_outbox3 6080001.9 MiB
clinical.node_cold0000152 KiB
clinical.node_hot157 26400050.9 MiB
clinical.template_ref200032 KiB
clinical.template_store2000192 KiB
clinical.version_cold0000160 KiB
clinical.version_hot3 6287030011.5 MiB
clinical.vo_head1 548985 1045 104576 KiB

Measured over 20 EHRs and 300 compositions of template Vital signs at commit 038571f9c7bc on 4 cores against PostgreSQL 18.6.

Schema generation generation-5, class s

OperationIterationsp50p95p99WALBuffer hits
create_first_version1 0704.4 ms4.5 ms4.5 ms35.4 MiB929 351
supersede8906.2 ms8.4 ms8.4 ms30.8 MiB2 161 169
supersede_if_match9406.4 ms6.7 ms6.7 ms31.6 MiB2 268 599
by_version_uid8 660490.7 µs609.3 µs609.3 µs208.4 KiB175 072
latest_by_versioned_object_uid8 980471.9 µs513.7 µs513.7 µs480 B159 656
version_at_time4 3401 ms1.1 ms1.1 ms120 B93 911
revision_history18 310254.5 µs257.7 µs257.7 µs0 B292 386
contains_one_ehr1 1603.7 ms3.8 ms3.8 ms120 B384 311
contains_population2 0402.4 ms2.5 ms2.5 ms0 B829 355
flat_2_sibling_leaves20024.4 ms27.5 ms27.5 ms22.9 KiB1 547 845
flat_3_sibling_leaves16034.5 ms35.5 ms35.5 ms0 B1 162 553
streaming_2_sibling_leaves6807.4 ms7.6 ms7.6 ms0 B2 402 326
streaming_3_sibling_leaves6407.9 ms8.2 ms8.2 ms0 B2 123 864
contains_exists20025.1 ms26.3 ms26.3 ms0 B9 821 144
node_predicate9505.3 ms5.4 ms5.4 ms0 B2 131 740
where_magnitude50106.3 ms110 ms110 ms0 B5 892 992
where_coded7706.6 ms6.7 ms6.7 ms0 B2 276 593
where_date_time8905.6 ms5.6 ms5.6 ms0 B2 028 107
where_text6008.3 ms8.4 ms8.4 ms0 B3 066 677
wide_projection_one_ehr13040.7 ms42.2 ms42.2 ms0 B221 332
wide_projection_population38013.3 ms13.7 ms13.7 ms0 B2 193 323
select_observation6407.5 ms7.6 ms7.6 ms0 B1 588 428
select_composition_one_ehr5608.7 ms9.1 ms9.1 ms0 B609 582
person_identifier_lookup9205.4 ms5.7 ms5.7 ms0 B85 064
ehr_by_subject11 750426.1 µs439.4 µs439.4 µs0 B31 884
aql_version_at_time1 2304.1 ms4.2 ms4.2 ms0 B1 718 186
archive_ehr20123.3 ms126.4 ms126.4 ms53.6 MiB1 517 281
restore_ehr20152.9 ms153.8 ms153.8 ms50.7 MiB1 512 465
retention_prune20 250211.6 µs246.1 µs246.1 µs0 B195 448

One representative commit wrote 522.1 KiB of WAL and touched 4 037 buffers. The population CONTAINS statement plans as Hash Join and reads 15 262 shared blocks.

RelationLive rowsDead rowsUpdatesHOT updatesSize
clinical.commit_audit7 1680001.8 MiB
clinical.contribution6 9680001.2 MiB
clinical.ehr100000232 KiB
clinical.event_outbox6 9680003.5 MiB
clinical.node_cold0000128 KiB
clinical.node_hot327 024000107.6 MiB
clinical.template_ref200032 KiB
clinical.template_store2000192 KiB
clinical.version_cold0000176 KiB
clinical.version_hot7 06800024.4 MiB
clinical.vo_head4 628556 0046 0021 MiB

Measured over 100 EHRs and 3 000 compositions of template Vital signs at commit 038571f9c7bc on 4 cores against PostgreSQL 18.6.

Schema generation generation-6, class poc

OperationIterationsp50p95p99WALBuffer hits
create_first_version1 0904.4 ms4.5 ms4.5 ms36.1 MiB824 416
supersede1 1404.9 ms5.6 ms5.6 ms6.6 MiB2 107 333
supersede_if_match1 1504.9 ms5.6 ms5.6 ms6.8 MiB2 137 821
by_version_uid13 890330.1 µs341.8 µs341.8 µs264 B247 429
latest_by_versioned_object_uid14 090319.2 µs325.3 µs325.3 µs61.3 KiB267 480
version_at_time6 470720.1 µs730 µs730 µs0 B155 540
revision_history28 310171.1 µs172.5 µs172.5 µs0 B475 590
contains_one_ehr1 1004.1 ms4.2 ms4.2 ms0 B1 980 115
contains_population3 1101.6 ms1.6 ms1.6 ms0 B856 480
flat_2_sibling_leaves39012.2 ms12.3 ms12.3 ms120 B1 465 992
flat_3_sibling_leaves31015.7 ms15.9 ms15.9 ms88 B1 132 214
streaming_2_sibling_leaves8905.7 ms5.8 ms5.8 ms0 B2 762 965
streaming_3_sibling_leaves8206.1 ms6.3 ms6.3 ms0 B2 809 134
contains_exists6108.2 ms8.3 ms8.3 ms0 B8 183 528
node_predicate1 2704 ms4 ms4 ms0 B2 450 930
where_magnitude10053.1 ms54 ms54 ms0 B5 256 697
where_coded1 0704.7 ms4.8 ms4.8 ms0 B2 293 782
where_date_time1 1204.5 ms4.5 ms4.5 ms0 B2 204 262
where_text1 0404.8 ms4.9 ms4.9 ms0 B2 345 683
wide_projection_one_ehr17029.2 ms29.3 ms29.3 ms232 B206 013
wide_projection_population5309.5 ms9.7 ms9.7 ms0 B2 498 769
select_observation8006 ms6.2 ms6.2 ms0 B2 022 934
select_composition_one_ehr1 2004 ms4.1 ms4.1 ms0 B936 215
person_identifier_lookup1 1404.2 ms4.3 ms4.3 ms0 B95 966
ehr_by_subject17 670282.1 µs284.3 µs284.3 µs0 B21 941
aql_version_at_time1 8402.7 ms2.7 ms2.7 ms0 B2 245 246
archive_ehr14020.3 ms26.7 ms26.7 ms158.7 MiB9 870 317
restore_ehr14019.2 ms20.2 ms20.2 ms157.9 MiB9 981 072
retention_prune30 680163.4 µs165.1 µs165.1 µs8.1 KiB312 083

One representative commit wrote 282.3 KiB of WAL and touched 3 975 buffers. The population CONTAINS statement plans as Nested Loop and reads 18 152 shared blocks.

RelationLive rowsDead rowsUpdatesHOT updatesSize
clinical.commit_audit4 5480001.3 MiB
clinical.contribution4 508000840 KiB
clinical.ehr4000064 KiB
clinical.event_outbox4 5080002.2 MiB
clinical.node_cold0000136 KiB
clinical.node_hot74 70400054.3 MiB
clinical.template_ref400032 KiB
clinical.template_store4000192 KiB
clinical.version_cold0000336 KiB
clinical.version_hot4 52800020.7 MiB
clinical.vo_head1 708015 13215 132648 KiB

Measured over 20 EHRs and 300 compositions of template Vital signs at commit 82225d6a88d8 on 4 cores against PostgreSQL 18.6.

Schema generation generation-6, class s

OperationIterationsp50p95p99WALBuffer hits
create_first_version1 0704.4 ms4.5 ms4.5 ms35.5 MiB926 429
supersede1 1804.8 ms5.5 ms5.5 ms7.5 MiB2 272 609
supersede_if_match1 1604.8 ms5.6 ms5.6 ms6.8 MiB2 184 054
by_version_uid13 600329.9 µs333.3 µs333.3 µs78.6 KiB252 125
latest_by_versioned_object_uid14 540317.9 µs320 µs320 µs456 B269 207
version_at_time6 300728.4 µs745.3 µs745.3 µs0 B144 639
revision_history27 680171.3 µs174.4 µs174.4 µs0 B467 444
contains_one_ehr1 7302.7 ms2.7 ms2.7 ms120 B612 490
contains_population2 5302 ms2 ms2 ms0 B1 554 199
flat_2_sibling_leaves33014.9 ms16.4 ms16.4 ms136 B1 698 808
flat_3_sibling_leaves25020 ms20.1 ms20.1 ms0 B1 224 810
streaming_2_sibling_leaves8505.9 ms6 ms6 ms0 B3 086 520
streaming_3_sibling_leaves8106.2 ms6.2 ms6.2 ms0 B3 187 586
contains_exists5309.3 ms9.4 ms9.4 ms0 B5 934 249
node_predicate1 1904.2 ms4.3 ms4.3 ms0 B2 879 980
where_magnitude7072.7 ms72.9 ms72.9 ms0 B4 837 545
where_coded1 1804.2 ms4.3 ms4.3 ms0 B2 485 551
where_date_time1 0904.6 ms4.7 ms4.7 ms0 B2 683 370
where_text7606.6 ms6.6 ms6.6 ms176 B4 173 294
wide_projection_one_ehr16031.1 ms31.3 ms31.3 ms0 B307 413
wide_projection_population5309.4 ms9.4 ms9.4 ms0 B2 549 897
select_observation7406.5 ms6.5 ms6.5 ms0 B2 396 855
select_composition_one_ehr7506.6 ms6.8 ms6.8 ms0 B907 948
person_identifier_lookup1 1104.4 ms4.4 ms4.4 ms56 B99 530
ehr_by_subject16 820293.6 µs305.4 µs305.4 µs0 B42 024
aql_version_at_time1 5603.1 ms3.2 ms3.2 ms0 B2 400 330
archive_ehr8034.8 ms45.8 ms45.8 ms204 MiB12 202 858
restore_ehr7034.7 ms35.8 ms35.8 ms152.7 MiB16 221 567
retention_prune30 880160.5 µs161 µs161 µs1.8 MiB390 958

One representative commit wrote 269.7 KiB of WAL and touched 1 182 buffers. The population CONTAINS statement plans as Hash Join and reads 5 530 shared blocks.

RelationLive rowsDead rowsUpdatesHOT updatesSize
clinical.commit_audit7 6780002 MiB
clinical.contribution7 4780001.3 MiB
clinical.ehr100000136 KiB
clinical.event_outbox7 4780003.8 MiB
clinical.node_cold0000120 KiB
clinical.node_hot222 104000129.5 MiB
clinical.template_ref200032 KiB
clinical.template_store2000192 KiB
clinical.version_cold0000312 KiB
clinical.version_hot7 57800039.2 MiB
clinical.vo_head4 628815 88615 8861 MiB

Measured over 100 EHRs and 3 000 compositions of template Vital signs at commit 82225d6a88d8 on 4 cores against PostgreSQL 18.6.

The published figures

The figures below are the last ones measured with the earlier generation of the instrument, the Veredictum 0.1 line: a proof-of-concept class run, the step-load stress ladder and the AQL probe, against FerroEHR 4.3.0. Veredictum 0.3.1 replaced those three instruments with perf, so they cannot be re-run. A perf-result record measured on the reference host replaces them, and these charts and their records go with it.

ClassCorpusOffered-load floorp99 budgetError budgetMeasured sustainedVerdict
POCcnf.scale.10k2/s≤ 1000 ms02.0/sEARNED
Scnf.scale.100k15/s≤ 1000 ms0—not measured
Lcnf.scale.1m150/s≤ 1000 ms0—not measured
Rcnf.scale.10m1500/s≤ 1000 ms0—not measured

Measured run PERF-hospital_sim-class_POC — class POC, offered load 2.04/s sustained over 3600 s (after 300 s warmup), environment: consumer-laptop (8 cores, 16 GB, nvme, single-node docker compose (8-CPU/8GB Docker VM) on Apple M2, the SMART resource-server posture (docker/sut-smart.yml overlays the base stack) with the external-terminology profile composed beside it (a seeded HAPI FHIR R4 server, docker compose –profile terminology + docker/sut-terminology.yml, fail-open); alongside it a second deployment of the same image in the openPGP version-signing posture (project ferroehr-cnf-pgp, docker/sut-signing-pgp.yml + docker/sut-terminology-failclosed.yml + docker/sut-pgp-parallel.yml, host port 8081) declared as the sut_pgp instance, which carries the fail-closed terminology posture — the measured-performance stage drives the primary deployment alone).

OperationRequestsErrorsp50 (ms)p90 (ms)p99 (ms)
adhoc_query7920293864
admin_contribution_report600159176269
analytics_query2306276197
archetype_adl2_list600131828
composition_commit280050106214
composition_commit_flat70425353
composition_delete40283535
composition_read15830243366
composition_read_current8960273657
composition_read_flat70172525
composition_revision_history8890142131
composition_update6804667239
composition_version_read300283549
contribution_commit48054138187
contribution_read820202860
directory_create120254086
directory_read8030172440
directory_update120283442
ehr_create120283233
ehr_extract_export7920149182268
ehr_read720182537
ehr_status_read240162325
ehr_status_update240213655
party_create60222828
party_read60162424
party_relationship_create60263030
party_relationship_read60111717
party_update60152727
readonly_write_denied70304646
smart_configuration_read70152424
stored_query_execute18004155103
system_options70101818
tags_put300243341
tags_read300172638
tdd_import70356060
template_adl2_list610131954
template_example60030102261
template_get60064134240
template_list600538090
terminology_query230192673
unauthenticated_probe70182323
ward_query1800283871

Resources (measured context, never a verdict input) — sampled every 10 s; CPU/RSS derived over the measured phase:

ContainerCPU meanCPU peakRSS peak
sut ferroehr-cnf-ferroehr-13.6%7.7%218 MB
db ferroehr-cnf-ferroehr-postgres-15.9%21.0%1.5 GB

Disk anchors: empty 133 MB → after scale seed 13 GB (≈ 13 KB / composition over 1,000,000 committed) → after ward seed 13 GB → after window 13 GB.