Documentation
¶
Overview ¶
Command loadgen is a self-contained load/soak + profiling harness for poseidon-http-server. Unlike the external-tool scripts in this directory (h2load/ghz/k6), it drives real poseidon servers end-to-end from Go, so it can:
- exercise a broad slice of the HTTP/2 + gRPC + middleware feature surface in one run (see loadtest/README.md for the honest covered/excluded list),
- stream arbitrarily large bodies (up to 10 GiB) from a fixed shared buffer, so memory stays flat regardless of -data-size,
- correlate variables across a weighted + conditional + nested scenario mix,
- fire a sharp traffic spike partway through a sustained soak,
- stream-parse large (multi-MiB) responses under load, and
- capture CPU/heap pprof profiles + a runtime resource report to show the server stays lean.
This file defines the feature servers (an HTTP mux server + a gRPC server); main.go defines the driver, scenarios, spike, profiling, and report. Build/run:
go run ./loadtest/loadgen -h
go run ./loadtest/loadgen -duration=20s -vus=64 -data-size=64MiB \
-spike-after=8s -spike-dur=6s -cpuprofile=cpu.out -memprofile=heap.out
Click to show internal directories.
Click to hide internal directories.