Documentation
¶
Overview ¶
Command bench is the native candidate of the Durable conformance gate (durable/contract/impls/native.mjs): the bench scenario (durable/contract/scenarios/bench.mjs) run through the native session on the core, with its statements written as a trace of statements only (contracttest.Writer), which the Node tools replay onto the starting store.
bench --db <store> --trace <out> [--seed N] [--turns N] [--tools N] [--variant full|incr] [--stream CHARS]
[--partial-ms MS] [--fault retryable-error] [--payload-kb K] [--parallel] [--recover] [--label L]
bench --db <store> --trace <out> --record <recording> ... also records what the core was given (durable/core/contracttest/counts)
bench --db <fixture copy> --timing <results.jsonl> --size N --sample I --version C [--turns 10] [--tools 8] [--cpuprofile FILE]
bench seed DIR SIZE [TARGET]
bench sample FIXTURE SIZE [INDEX] [TARGET] [VERSION]
seed and sample are durable/interop/bench.mjs's commands for the native core (k8s.go), so a benchmark profile measures both the same way (bench/k8s, profile durable-core).
--timing measures instead of tracing (the benchmark report's native build, bench/durable/report/RUNNER-SPEC.md): it runs on the real clock with no statement trace, checks the fixture's seed fingerprint and appends one durable-bench bench/run.ts line per run (timingLine). --cpuprofile writes the pprof CPU profile of that measured run.
CONTRACT_CRASH_AFTER=<seq> kills the process right after the commit that consumed that seq (contracttest.Writer).