Expand description
Tokio runtime helpers.
SP-concurrency-baseline §5.1 — default_worker_threads() chooses a sensible
default for ATD reference binaries: min(available_parallelism, 4),
overridable via ATD_WORKER_THREADS env. The 4-thread cap prevents a
reference binary launched on a 32-core dev machine from spawning 32 idle
worker threads per process (adopter test suites that spin up several
ref-server instances would otherwise pay 100s of idle threads).
Functions§
- default_
worker_ threads - Returns the recommended tokio
worker_threadscount for an ATD server binary. ReadsATD_WORKER_THREADSif set; otherwise defaults tomin(available_parallelism, 4), falling back to2if the OS query fails.