diff --git a/README.md b/README.md index 36d74df..db3ea72 100644 --- a/README.md +++ b/README.md @@ -20,10 +20,19 @@ claims; neither is inferred from the implementation language. The goal is to keep WireMock's familiar mappings and APIs while reducing the resources needed to run mock services in local development, CI and test -environments. In our latest measured Java-versus-Go workloads, optimized -BreakMock delivered **14–30% higher throughput**, used **32–45% less server CPU -at the same 10,000 RPS**, and had a much smaller resident memory footprint. -Median readiness was **10.7 ms for Go versus 600.7 ms for Java**. +environments. In the latest Java-versus-Go measurements (2026-10-13, commit +`68cd311`): + +- **Small responses** (a 17-byte body and a small template): BreakMock delivered + **22–50% higher throughput**, used **23–34% less server CPU** at the same + 10,000 RPS and **90–92% less memory** (28–43 MiB versus 259–490 MiB). +- **Large JSON responses** (inline, body files, templates and gzip): the larger + the body, the bigger the lead. At ~100 KiB BreakMock delivered **1.3–10.6× the + throughput** with **54–96% less server CPU**; at ~1 MiB **3.1–86×** with + **85–99% less**; at ~10 MiB **3.0–208×** with **92–99.5% less**, using + 0.4–0.9 GiB of memory where Java used 11.1–12.4 GiB. Responses were + byte-identical to Java's. +- Median readiness was **10.7 ms for Go versus 600.7 ms for Java**. These results are the basis for the refactor: lower resource use and faster startup while retaining WireMock compatibility as the target. We chose Go as @@ -154,61 +163,135 @@ bounded differential corpus, not the entire upstream Java test suite. ## Java versus Go benchmarks -Latest measured comparison: **2026-10-12**, Apple M4 Pro (14 logical CPUs), macOS -arm64, Go 1.27.1 and OpenJDK 27. Java is **WireMock 4.0.0-beta.40**; Go is optimized -BreakMock at commit `7176b12`. Both servers use the same workload driver and -32 persistent clients. The workloads are a static response and the template +Measured **2026-10-13** on an Apple M4 Pro (14 logical CPUs, 48 GB), macOS arm64, +Go 1.27.1 and OpenJDK 27. Java is **WireMock 4.0.0-beta.40** (JAR SHA-256 checked +against `testdata/reference.json`) with default JVM settings. Go is BreakMock built +from a clean checkout of commit `68cd311`; every report records that commit, a +clean tree and the binary's SHA-256. The same Go load generator drives both servers +in alternating order with 32 persistent connections and checks every response body. +All runs had zero errors and zero dropped arrivals. Journals were disabled or +capped at 1,000 entries on both servers. + +### Small responses + +The workloads are a static 17-byte body and the template `Hello {{request.query.name}}: {{math 2 '+' 3}}`. -Mean throughput at saturation (higher is better), two rounds per workload with -3 seconds of warmup and 5 seconds of measurement: +Throughput at saturation, requests per second (two rounds, 3 s warmup, 5 s +measurement; higher is better): -| Request journal | Workload | Java RPS | Go RPS | Go improvement | +| Request journal | Workload | Java | Go | Go vs Java | | --- | --- | ---: | ---: | ---: | -| Disabled | Static | 86,580 | 112,381 | +29.8% | -| Disabled | Template | 88,663 | 109,233 | +23.2% | -| Capped at 1,000 entries | Static | 77,532 | 92,829 | +19.7% | -| Capped at 1,000 entries | Template | 80,176 | 91,119 | +13.6% | - -Resource use at **the same 10,000 offered RPS** (lower is better), three rounds -with 10 seconds of warmup and 15 seconds of measurement. CPU is mean process -user+system time per completed request across all server threads, excluding the -load generator. Memory is the range of peak sampled RSS across rounds. - -| Request journal | Workload | Java CPU µs/request | Go CPU µs/request | Java RSS MiB | Go RSS MiB | -| --- | --- | ---: | ---: | ---: | ---: | -| Disabled | Static | 85.44 | 46.69 | 310.4–347.3 | 25.8–26.6 | -| Disabled | Template | 88.31 | 50.16 | 320.2–361.6 | 25.3–26.0 | -| Capped at 1,000 entries | Static | 113.33 | 74.64 | 334.6–364.6 | 37.7–39.9 | -| Capped at 1,000 entries | Template | 114.89 | 78.47 | 396.8–691.0 | 37.9–38.4 | - -Startup measured 15 fresh processes per implementation with warm OS caches. -Readiness requires loading a mapping from disk and returning the correct templated -response. Median readiness was **600.7 ms for Java and 10.7 ms for Go**; median -RSS at readiness was **206.0 MiB and 16.6 MiB**, respectively. - -All measured Java/Go load runs had zero errors or dropped arrivals, and matched-rate -runs achieved within 2% of the target. These are short, same-host measurements of -small workloads; the client shares the host, and Java's fixed warmup does not -prove JIT steady state. Journals were disabled or capped equally on both servers; -**the default unbounded journal was not benchmarked**. RSS is sampled every 100 ms. -These results predate subsequent admin compatibility fixes and Toxiproxy -integration, so they are not measurements of the current executable or active -chaos scenarios. Compatibility coverage is tracked separately in -[COMPATIBILITY.md](docs/COMPATIBILITY.md). - -See the [full measurement protocol and optimization report](docs/GO_JOURNAL_OPTIMIZATION.md), -[raw results and executable hashes](testdata/reports/go-optimized), and -[historical benchmarks](docs/BENCHMARKS.md). Reproduce the Java/Go workloads with: +| Disabled | Static | 72,580 | 108,579 | **+49.6%** | +| Disabled | Template | 82,988 | 105,756 | **+27.4%** | +| Capped at 1,000 | Static | 73,328 | 89,549 | **+22.1%** | +| Capped at 1,000 | Template | 72,037 | 87,565 | **+21.6%** | + +Server CPU and memory at **the same 10,000 offered RPS** (three rounds, 10 s +warmup, 15 s measurement; lower is better). CPU is process user+system time per +completed request across all server threads, excluding the load generator. +Memory is the range of peak sampled RSS across rounds. + +| Request journal | Workload | Java CPU µs/req | Go CPU µs/req | CPU saved | Java RSS MiB | Go RSS MiB | +| --- | --- | ---: | ---: | ---: | ---: | ---: | +| Disabled | Static | 84.29 | 55.67 | **−34.0%** | 259.3–378.3 | 28.1–28.7 | +| Disabled | Template | 85.87 | 66.44 | **−22.6%** | 281.8–402.9 | 28.9–29.2 | +| Capped at 1,000 | Static | 122.42 | 86.49 | **−29.4%** | 372.2–429.5 | 42.1–42.6 | +| Capped at 1,000 | Template | 120.91 | 84.71 | **−29.9%** | 402.0–490.4 | 43.0–43.3 | + +At saturation, Go also used 27–43% less CPU per request. Peak RSS at saturation +was 504–897 MiB for Java and 31–53 MiB for Go; idle RSS after startup was +176–200 MiB and 18–20 MiB. Mean p99 latency at 10,000 RPS was 2.5–3.8 ms for Go +and 2.0–6.1 ms for Java, so Go did **not** have lower tail latency at this +moderate rate; arrivals are dispatched in 1 ms batches, which dominates these +values. + +### Large JSON responses + +The workloads serve a ~100 KiB JSON document as inline `jsonBody`, inline `body`, +`bodyFileName`, templates (straight-line and full Handlebars with `jsonPath`) and +gzip. Three rounds, 2 s warmup, 5 s measurement, saturation. BreakMock before +this work (`51ac179`) ran in the same session: + +| Request journal | Workload | Java RPS | Go before RPS | Go RPS | Go vs Java | Java CPU µs/req | Go CPU µs/req | Java peak RSS MiB | Go peak RSS MiB | +| --- | --- | ---: | ---: | ---: | ---: | ---: | ---: | ---: | ---: | +| Disabled | jsonBody | 8,234 | 19,674 | 57,429 | **7.0×** | 1,012.9 | 83.2 | 3,631 | 34 | +| Disabled | body | 26,370 | 33,900 | 54,273 | **2.1×** | 318.3 | 81.1 | 3,271 | 34 | +| Disabled | bodyFileName | 13,966 | 27,221 | 54,505 | **3.9×** | 647.7 | 88.9 | 2,359 | 34 | +| Disabled | Template | 21,885 | 430 | 34,526 | **1.6×** | 381.0 | 151.7 | 3,145 | 40 | +| Disabled | Template file | 16,564 | 450 | 33,245 | **2.0×** | 537.4 | 160.9 | 2,915 | 41 | +| Disabled | Template + jsonPath | 21,136 | 459 | 28,312 | **1.3×** | 393.6 | 179.8 | 4,295 | 42 | +| Disabled | jsonBody, gzip | 8,245 | 13,142 | 87,070 | **10.6×** | 1,197.7 | 44.6 | 5,486 | 42 | +| Capped at 1,000 | jsonBody | 8,979 | 25,730 | 54,640 | **6.1×** | 1,034.7 | 97.2 | 5,656 | 392 | +| Capped at 1,000 | Template + jsonPath | 17,853 | 590 | 48,728 | **2.7×** | 455.4 | 118.4 | 6,329 | 440 | +| Capped at 1,000 | jsonBody, gzip | 8,143 | 14,221 | 79,141 | **9.7×** | 1,214.2 | 66.8 | 6,208 | 441 | + +All 14 combinations, p99 latency and the measurement details are in the +[large JSON report](docs/LARGE_JSON_OPTIMIZATION.md). Every Go response was +byte-identical to Java's. + +The lead grows with body size (journal disabled; Go throughput as a multiple of +Java's, and Go's CPU saving per request): + +| Workload | ~100 KiB | ~1 MiB | ~10 MiB | +| --- | ---: | ---: | ---: | +| jsonBody | 7.0× (−92%) | 10.0× (−97%) | 15.7× (−98%) | +| body | 2.1× (−75%) | 3.7× (−90%) | 3.2× (−94%) | +| bodyFileName | 3.9× (−86%) | 3.1× (−87%) | 3.0× (−92%) | +| Template | 1.6× (−60%) | 4.5× (−86%) | 5.7× (−95%) | +| Template + jsonPath | 1.3× (−54%) | 4.4× (−85%) | 4.6× (−94%) | +| jsonBody, gzip | 10.6× (−96%) | 76× (−99%) | 208× (−99.5%) | +| Peak RSS, Java → Go | 2.3–5.4 GiB → 34–42 MiB | 3.0–5.0 GiB → 60–145 MiB | 11.1–12.4 GiB → 436–898 MiB | + +At ~1 MiB and above, Go's static and template workloads reach ~10 GB/s through +loopback, the shared load generator's limit, so CPU per request is the fairer +comparison there. Details: [scaling with body size](docs/LARGE_JSON_OPTIMIZATION.md#scaling-with-body-size). + +### What improved in this release + +- **Large responses:** templated bodies of 64 KiB and more were re-parsed on every + request, so Go was 30–51× *slower* than Java there; it is now 1.3–3.2× faster. + Inline, file and gzip bodies use 39–94% less CPU than before, and peak RSS fell + by about half or more. +- **Small responses** were already optimized and are unchanged: an in-process + A/B of the exact workloads above (`BenchmarkSmallResponse`, alternating builds) + is within ±2% ([raw output](testdata/reports/benchmark-small-ab.txt)). + +### Scope + +These are short, same-host measurements: the load generator shares the CPU, and +Java's fixed warmup does not prove JIT steady state. Results vary between runs on +this host (for example, Java's saturation RPS differed by up to 17% from a run the +day before), so compare implementations within one run, not across runs. Java ran +with its default heap (about a quarter of RAM), so its RSS shows what the JVM took, +not the minimum it needs. **The default unbounded journal was not benchmarked.** +RSS is sampled every 100 ms. Startup was measured separately on 15 fresh processes +per implementation with warm OS caches, loading a mapping from disk and returning a +templated response; median RSS at readiness was 206.0 MiB for Java and 16.6 MiB +for Go. Compatibility is tracked separately in [COMPATIBILITY.md](docs/COMPATIBILITY.md). + +Raw results with commit, executable and JAR hashes: +[small responses](testdata/reports/java-go-2026-10-13) and large JSON at +[100 KiB](testdata/reports/benchmark-large-json.json), +[1 MiB](testdata/reports/benchmark-large-json-1mib.json) and +[10 MiB](testdata/reports/benchmark-large-json-10mib.json). Earlier measurements +are in [BENCHMARKS.md](docs/BENCHMARKS.md) and +[GO_JOURNAL_OPTIMIZATION.md](docs/GO_JOURNAL_OPTIMIZATION.md). + +Reproduce: ```sh -# Saturation throughput, without and with a bounded journal. +# Small responses: saturation throughput, then CPU and memory at 10,000 RPS. python3 scripts/benchmark.py --jar /tmp/wiremock.jar --servers java,go --rounds 2 --duration 5s --output /tmp/throughput.json python3 scripts/benchmark.py --jar /tmp/wiremock.jar --servers java,go --rounds 2 --duration 5s --journal-limit 1000 --output /tmp/throughput-journal.json - -# CPU and memory at the same offered request rate. python3 scripts/benchmark.py --jar /tmp/wiremock.jar --servers java,go --rate 10000 --warmup 10s --duration 15s --rounds 3 --output /tmp/cpu-10k.json python3 scripts/benchmark.py --jar /tmp/wiremock.jar --servers java,go --rate 10000 --warmup 10s --duration 15s --rounds 3 --journal-limit 1000 --output /tmp/cpu-10k-journal.json + +# Large JSON responses; list Java first so its responses are the byte reference. +# Add --size 1048576, or --size 10485760 --journal disabled, for the scaling runs. +go build -trimpath -o /tmp/breakmock ./cmd/breakmock +python3 scripts/json_benchmark.py --binary java=/tmp/wiremock.jar --binary go=/tmp/breakmock \ + --rounds 3 --duration 5s --warmup 2s --journal-check report --output /tmp/large-json.json ``` ## License and provenance diff --git a/cmd/bmbench/main.go b/cmd/bmbench/main.go index 68727b9..fce4f6f 100644 --- a/cmd/bmbench/main.go +++ b/cmd/bmbench/main.go @@ -3,6 +3,7 @@ package main import ( + "bytes" "encoding/json" "flag" "fmt" @@ -10,6 +11,7 @@ import ( "net/http" "os" "sort" + "strings" "sync" "sync/atomic" "time" @@ -21,14 +23,39 @@ func main() { rate := flag.Int("rate", 0, "Offered requests per second; 0 means unlimited") expected := flag.String("expected-body", "", "Expected response body, when supplied") workers := flag.Int("concurrency", 32, "Concurrent persistent connections") + method := flag.String("method", http.MethodGet, "Request method") + requestBodyFile := flag.String("body-file", "", "File sent as each request body, when supplied") + expectedFile := flag.String("expected-body-file", "", "File holding the exact expected response body, when supplied") + var headers headerFlags + flag.Var(&headers, "header", "Request header as 'Name: value'; repeatable") flag.Parse() + var requestBody, expectedBody []byte + checkBody := *expected != "" + if checkBody { + expectedBody = []byte(*expected) + } + for _, file := range []struct { + path string + into *[]byte + }{{*requestBodyFile, &requestBody}, {*expectedFile, &expectedBody}} { + if file.path == "" { + continue + } + data, err := os.ReadFile(file.path) + if err != nil { + fmt.Fprintln(os.Stderr, err) + os.Exit(2) + } + *file.into = data + } + checkBody = checkBody || *expectedFile != "" if *rate < 0 || *workers < 1 || *duration <= 0 { fmt.Fprintln(os.Stderr, "rate must be nonnegative; concurrency and duration must be positive") os.Exit(2) } transport := &http.Transport{MaxIdleConns: *workers, MaxIdleConnsPerHost: *workers, MaxConnsPerHost: *workers, DisableCompression: true} client := &http.Client{Transport: transport, Timeout: 10 * time.Second} - var requests, failures, dropped atomic.Int64 + var requests, failures, dropped, received atomic.Int64 var mu sync.Mutex var samples []int64 var wg sync.WaitGroup @@ -67,6 +94,7 @@ func main() { go func() { defer wg.Done() local := make([]int64, 0, 10000) + var buffer bytes.Buffer for { t := time.Now() if jobs != nil { @@ -78,19 +106,32 @@ func main() { } else if !time.Now().Before(deadline) { break } - r, e := client.Get(*target) + request, e := http.NewRequest(*method, *target, bytes.NewReader(requestBody)) + if e != nil { + fmt.Fprintln(os.Stderr, e) + os.Exit(2) + } + if requestBody == nil { + request.Body = http.NoBody + } + for _, h := range headers { + request.Header.Add(h.name, h.value) + } + r, e := client.Do(request) if e != nil { failures.Add(1) continue } - var body []byte - if *expected != "" { - body, e = io.ReadAll(r.Body) + var n int64 + if checkBody { + buffer.Reset() + n, e = buffer.ReadFrom(r.Body) } else { - _, e = io.Copy(io.Discard, r.Body) + n, e = io.Copy(io.Discard, r.Body) } r.Body.Close() - if e != nil || r.StatusCode != 200 || (*expected != "" && string(body) != *expected) { + received.Add(n) + if e != nil || r.StatusCode != 200 || (checkBody && !bytes.Equal(buffer.Bytes(), expectedBody)) { failures.Add(1) } requests.Add(1) @@ -110,10 +151,23 @@ func main() { } return float64(samples[int(float64(len(samples)-1)*p)]) / 1000 } - report := map[string]any{"url": *target, "target_rps": *rate, "dropped": dropped.Load(), "concurrency": *workers, "seconds": elapsed, "requests": requests.Load(), "errors": failures.Load(), "rps": float64(requests.Load()) / elapsed, "p50_ms": percentile(.5), "p95_ms": percentile(.95), "p99_ms": percentile(.99)} + report := map[string]any{"url": *target, "target_rps": *rate, "dropped": dropped.Load(), "concurrency": *workers, "seconds": elapsed, "requests": requests.Load(), "errors": failures.Load(), "rps": float64(requests.Load()) / elapsed, "response_bytes": received.Load(), "p50_ms": percentile(.5), "p95_ms": percentile(.95), "p99_ms": percentile(.99)} data, _ := json.Marshal(report) fmt.Println(string(data)) if failures.Load() > 0 || dropped.Load() > 0 { os.Exit(1) } } + +type header struct{ name, value string } +type headerFlags []header + +func (h *headerFlags) String() string { return fmt.Sprint(*h) } +func (h *headerFlags) Set(value string) error { + name, v, ok := strings.Cut(value, ":") + if !ok || strings.TrimSpace(name) == "" { + return fmt.Errorf("header must be 'Name: value'") + } + *h = append(*h, header{strings.TrimSpace(name), strings.TrimSpace(v)}) + return nil +} diff --git a/cmd/bmbench/main_test.go b/cmd/bmbench/main_test.go index 2aa8f90..2f86e8a 100644 --- a/cmd/bmbench/main_test.go +++ b/cmd/bmbench/main_test.go @@ -3,8 +3,10 @@ package main import ( "encoding/json" + "io" "net/http" "net/http/httptest" + "os" "os/exec" "path/filepath" "sync/atomic" @@ -41,3 +43,30 @@ func TestFixedRateAndBodyValidation(t *testing.T) { } } } + +func TestRequestBodyHeadersAndExpectedFile(t *testing.T) { + dir := t.TempDir() + binary := filepath.Join(dir, "bmbench") + if out, err := exec.Command("go", "build", "-o", binary, "main.go").CombinedOutput(); err != nil { + t.Fatalf("build: %v: %s", err, out) + } + server := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { + body, _ := io.ReadAll(r.Body) + _, _ = w.Write([]byte(r.Method + " " + r.Header.Get("X-Test") + " " + string(body))) + })) + defer server.Close() + request, expected := filepath.Join(dir, "request.json"), filepath.Join(dir, "expected") + os.WriteFile(request, []byte(`{"a":1}`), 0o644) + os.WriteFile(expected, []byte(`POST yes {"a":1}`), 0o644) + out, err := exec.Command(binary, "--url", server.URL, "--rate", "50", "--duration", "200ms", "--concurrency", "2", "--method", "POST", "--header", "X-Test: yes", "--body-file", request, "--expected-body-file", expected).Output() + if err != nil { + t.Fatalf("%v: %s", err, out) + } + var report struct { + Requests, Errors int64 + ResponseBytes int64 `json:"response_bytes"` + } + if err := json.Unmarshal(out, &report); err != nil || report.Requests != 10 || report.Errors != 0 || report.ResponseBytes != 10*16 { + t.Fatalf("unexpected report %s", out) + } +} diff --git a/docs/BENCHMARKS.md b/docs/BENCHMARKS.md index 7207dce..0b81e65 100644 --- a/docs/BENCHMARKS.md +++ b/docs/BENCHMARKS.md @@ -1,5 +1,11 @@ # Benchmark measurements +**Latest results (2026-10-13)** are in the README's +[Java versus Go benchmarks](../README.md#java-versus-go-benchmarks): small responses +(raw data in `testdata/reports/java-go-2026-10-13/`) and ~100 KiB JSON responses +([large JSON report](LARGE_JSON_OPTIMIZATION.md)). The measurements below are +historical and describe earlier builds. + The latest [optimized Java/Go/Rust comparison](GO_JOURNAL_OPTIMIZATION.md) includes the Go allocation/locking improvements, the preceding Rust journal fix, and a fresh run of all the original runtime benchmark settings. diff --git a/docs/COMPATIBILITY.md b/docs/COMPATIBILITY.md index 3223a90..8a55e25 100644 --- a/docs/COMPATIBILITY.md +++ b/docs/COMPATIBILITY.md @@ -51,13 +51,17 @@ timestamps, measured timings and local origins. Fixed IDs and application values are preserved. This is formatting equivalence with those substitutions, **not** literal equality of every byte from two independent server processes. -A strict diagnostic case remains failing: WireMock prints a JVM byte-array object -identity (`[B@...`) for a binary matcher mismatch. Identical requests to the same -Java server produce different identities. The report preserves the failing -comparison and repeated-Java evidence; it does not normalize this into a pass. -The [message-wait fixes and Java self-comparison](COMPATIBILITY_FIXES.md) document -the latest verification: both native implementations retain only this one failing -case in the tested corpus, and unmodified Java also fails the exact self-comparison. +One diagnostic contains a value that no other process can reproduce: for a +binary matcher mismatch, WireMock prints the actual body as Java's default +`byte[]` string, `[B@` followed by a per-object JVM identity hash (for example +`[B@6b9cd557`). Identical requests to the same Java server produce different +identities. BreakMock prints the same form with a random identity. For this one +case the suite replaces the `[B@` token **and its padding** with a placeholder +of the same width on both sides, requires exactly one such token on each side, and +compares every other byte, including column alignment. BreakMock builds that print +anything else (earlier builds printed base64) still fail. See +[COMPATIBILITY_FIXES.md](COMPATIBILITY_FIXES.md) for the evidence that Java's value +is non-deterministic. The harness does not claim universal TCP/HTTP header order, chunk boundaries, Date values, HTTP/2 frames, scheduling jitter or random-output equivalence. @@ -89,6 +93,19 @@ locale data can change between JDK releases. listener wrapper (enabled by the CLI). Embedding without it loses those details. - WireMock Cloud proprietary code and extensions such as gRPC/GraphQL are not included. Future test-data and chaos features require independent implementation. +- HTTP request header values are decoded as ISO-8859-1, one character per byte, as + Jetty does. Matching, templates, cookies and the journal therefore see a UTF-8 + `é` sent in a header as `é`, exactly like WireMock. +- Template syntax errors are not yet Java-compatible. Handlebars.java renders some + malformed input as literal text (for example an unclosed `{{foo` or a single `}`), + where BreakMock returns an error, and its error messages use a different format + (`[ERROR] line:col: found: …, expected: …`). Well-formed templates are unaffected. +- Intentional divergence: after a templated body file is edited, WireMock keeps + serving its cached compiled template until the mapping changes. BreakMock serves + the edited file immediately. +- Request journals differ for templated responses (WireMock logs the rendered body + in `responseDefinition`) and for gzip responses (WireMock logs the uncompressed + body). Served bytes are identical. - Runtime comparisons cover two small workloads. See `BENCHMARKS.md` for the latest optimized Go/Rust results and their limits; broader workloads remain unmeasured. @@ -109,7 +126,7 @@ Consolidated local Go and Rust runs (2026-10-12), retained under | HTTP admin | 130/130 | JSON bytes with explicit scalar substitutions | | Runtime/proxy | 46/46 | Body bytes and selected headers | | Gzip | 99/99 | Compressed bytes and negotiation | -| Diagnostics | 40/41 | Exact bytes; JVM identity case fails | +| Diagnostics | 41/41 | Exact bytes; one JVM identity token masked width-for-width | | Near-miss distances | 140/140 | Exact admin response bytes | | Webhooks | 7/7 | Configured callback content; transport headers separate | | Faults | 32/32 | Complete socket bytes and reset behavior | @@ -121,8 +138,16 @@ Consolidated local Go and Rust runs (2026-10-12), retained under | Message waits, enabled journal | 15/15 | Existing scalar substitutions; new error cases use exact bytes | | Message waits, disabled journal | 5/5 | Existing origin substitution; new precedence cases use exact bytes | | Concurrent journal | 16 invariants + 3 byte comparisons | Two exact admin responses; one with generated scalar substitutions | +| Templates inside 80 KB bodies, 3 requests each | 429/429 | Status and response bytes, including errors | +| Dynamic templates, edits and journal integrity | 238/238 | Exact bytes per request, at 2 sizes; random/time helpers by property | -`go test -race ./...` and `go vet ./...` pass. The strict differential runner -returns nonzero because the JVM-identity diagnostic remains a failure. +The last two rows were run on 2026-10-12 against Java with `template_differential.py --pad 80000 --repeat 3` +and `dynamic_template_differential.py`. That suite checks values that vary by request, +random and time helpers, mapping/file/jsonBody edits with gzip, raw non-ASCII header +bytes, and that journal entries hold the body served to each of 120 concurrent requests. +Its `--discover` mode adds the known template syntax-error cases. + +`go test -race ./...` and `go vet ./...` pass, and the strict differential runner +passes every suite (2026-10-13). Outgoing compressed WebSocket frame byte identity is not established; incoming compressed-message limits are exercised against Java. diff --git a/docs/COMPATIBILITY_FIXES.md b/docs/COMPATIBILITY_FIXES.md index 6c263f2..cfbb229 100644 --- a/docs/COMPATIBILITY_FIXES.md +++ b/docs/COMPATIBILITY_FIXES.md @@ -42,6 +42,13 @@ document that no existing comparisons were weakened. ## Why the last assertion cannot be fixed in a native implementation +> **Update 2026-10-13:** resolved by agreement to compare the shape of this value +> rather than its bytes. BreakMock now prints `[B@` with a random identity hash, +> as Java does, and `diagnostics_differential.py` masks only that token (keeping +> its column width) for this case, requiring one token on each side. All other +> bytes are compared. See [COMPATIBILITY.md](COMPATIBILITY.md#byte-comparison-boundaries). +> The analysis below explains why the value itself cannot match. + For the same binary matcher and request, Java emits lines such as: ```text diff --git a/docs/LARGE_JSON_OPTIMIZATION.md b/docs/LARGE_JSON_OPTIMIZATION.md new file mode 100644 index 0000000..7067f96 --- /dev/null +++ b/docs/LARGE_JSON_OPTIMIZATION.md @@ -0,0 +1,288 @@ +# Large JSON responses: optimization and Java comparison + +Earlier benchmarks served 17-byte bodies, so per-request costs that grow with body +size never showed up. This pass benchmarks large JSON documents served seven +ways: inline `jsonBody`, inline `body`, `bodyFileName`, response templates and +gzip. It found and removed several such costs, then compared the result with +WireMock 4.0.0-beta.40. + +At ~100 KiB, the optimized BreakMock served **1.3–10.6× the throughput of Java +WireMock**, with **54–96% less server CPU** per request and **91–99% less peak +RSS**, on all 14 workload/journal combinations. The lead grows with body size: +**3.1–86×** at ~1 MiB and **3.0–208×** at ~10 MiB. Before this work, BreakMock +was **30–51× slower than Java** for large templated bodies. + +Measured on 2026-10-13 from a clean checkout of commit `68cd311` on an Apple M4 +Pro (14 logical CPUs, 48 GB), macOS arm64, Go 1.27.1, OpenJDK 27 (Homebrew). +The JAR's SHA-256 matches `testdata/reference.json`. Every response from every +Go build was **byte-identical to Java's response**, gzip-compressed bodies +included; the load generator checked every response. + +## Java WireMock vs optimized BreakMock + +`scripts/json_benchmark.py` ran Java WireMock, BreakMock before this work +(`51ac179`) and the optimized BreakMock in one session. Servers ran one at a time +on the same port, in rotating order, for 3 rounds. Each workload used 32 +persistent connections, a 2 s warmup and a 5 s measurement. The same Go load +generator drove all three and shares the host with them. Journals were either +disabled or capped at 1,000 entries on every server. + +Throughput, requests per second (mean of 3 rounds; higher is better): + +| Journal | Workload | Java | BreakMock before | BreakMock optimized | Optimized vs Java | +| --- | --- | ---: | ---: | ---: | ---: | +| off | jsonBody | 8,234 | 19,674 | 57,429 | 6.97× | +| off | body | 26,370 | 33,900 | 54,273 | 2.06× | +| off | bodyFileName | 13,966 | 27,221 | 54,505 | 3.90× | +| off | templateBody | 21,885 | 430 | 34,526 | 1.58× | +| off | templateFile | 16,564 | 450 | 33,245 | 2.01× | +| off | templateHelper | 21,136 | 459 | 28,312 | 1.34× | +| off | jsonBodyGzip | 8,245 | 13,142 | 87,070 | 10.56× | +| 1,000 | jsonBody | 8,979 | 25,730 | 54,640 | 6.09× | +| 1,000 | body | 22,167 | 39,481 | 52,819 | 2.38× | +| 1,000 | bodyFileName | 12,912 | 28,685 | 52,899 | 4.10× | +| 1,000 | templateBody | 19,348 | 517 | 48,061 | 2.48× | +| 1,000 | templateFile | 15,839 | 497 | 50,698 | 3.20× | +| 1,000 | templateHelper | 17,853 | 590 | 48,728 | 2.73× | +| 1,000 | jsonBodyGzip | 8,143 | 14,221 | 79,141 | 9.72× | + +Server CPU per completed request, µs (all server threads, excluding the load +generator; mean of 3 rounds; lower is better): + +| Journal | Workload | Java | BreakMock before | BreakMock optimized | Optimized vs Java | +| --- | --- | ---: | ---: | ---: | ---: | +| off | jsonBody | 1,012.9 | 341.6 | 83.2 | −92% | +| off | body | 318.3 | 154.5 | 81.1 | −75% | +| off | bodyFileName | 647.7 | 239.0 | 88.9 | −86% | +| off | templateBody | 381.0 | 23,125.4 | 151.7 | −60% | +| off | templateFile | 537.4 | 23,315.1 | 160.9 | −70% | +| off | templateHelper | 393.6 | 23,720.4 | 179.8 | −54% | +| off | jsonBodyGzip | 1,197.7 | 710.3 | 44.6 | −96% | +| 1,000 | jsonBody | 1,034.7 | 305.8 | 97.2 | −91% | +| 1,000 | body | 379.5 | 160.7 | 97.3 | −74% | +| 1,000 | bodyFileName | 693.2 | 243.3 | 102.0 | −85% | +| 1,000 | templateBody | 452.4 | 19,017.5 | 109.9 | −76% | +| 1,000 | templateFile | 611.0 | 18,836.5 | 116.2 | −81% | +| 1,000 | templateHelper | 455.4 | 18,674.9 | 118.4 | −74% | +| 1,000 | jsonBodyGzip | 1,214.2 | 702.7 | 66.8 | −95% | + +p99 latency, ms (mean of 3 rounds; lower is better): + +| Journal | Workload | Java | BreakMock before | BreakMock optimized | +| --- | --- | ---: | ---: | ---: | +| off | jsonBody | 49.20 | 5.54 | 1.07 | +| off | body | 5.49 | 2.87 | 1.34 | +| off | bodyFileName | 16.97 | 3.60 | 1.28 | +| off | templateBody | 7.62 | 272.60 | 2.84 | +| off | templateFile | 12.89 | 238.24 | 3.05 | +| off | templateHelper | 8.70 | 211.58 | 5.22 | +| off | jsonBodyGzip | 33.00 | 8.12 | 1.68 | +| 1,000 | jsonBody | 38.07 | 5.11 | 1.54 | +| 1,000 | body | 8.99 | 2.67 | 1.55 | +| 1,000 | bodyFileName | 15.35 | 5.49 | 1.51 | +| 1,000 | templateBody | 9.76 | 193.70 | 2.18 | +| 1,000 | templateFile | 11.42 | 206.02 | 1.87 | +| 1,000 | templateHelper | 13.87 | 137.05 | 2.10 | +| 1,000 | jsonBodyGzip | 29.92 | 9.69 | 1.36 | + +Peak sampled RSS, MiB (highest across rounds; lower is better). Each server +process runs every workload in sequence, so later workloads include earlier +growth. Java ran with default JVM heap settings: + +| Journal | Java | BreakMock before | BreakMock optimized | +| --- | ---: | ---: | ---: | +| off | 2,359–5,486 | 69–90 | 34–42 | +| 1,000 | 4,345–6,562 | 966–1,176 | 392–441 | + +With a 1,000-entry journal, BreakMock keeps ≈400 MiB because the journal holds +1,000 copies of ~100 KiB bodies. + +Notes: + +- The static workloads reach about 53–57k RPS, which moves ≈5.3 GB/s through + loopback. At that point the shared load generator and kernel appear to be the + limit, so use the CPU table to compare those workloads. +- Java got the same 2 s warmup per workload as Go. Its JIT also warmed up during + earlier workloads in the same process. Results vary between rounds and runs on + this host; every round is in the raw report. +- These are same-host observations of one mock workload shape. They are not + capacity guarantees for other hardware, JVM settings or mappings. + +## Scaling with body size + +The same workloads at ~1 MiB and ~10 MiB, Java and the optimized BreakMock, with +the same settings. Every Go response was again byte-identical to Java's. The +100 KiB columns come from the run above. BreakMock's advantage **grows with body +size**: per request, Java's CPU rises roughly in proportion to the body, while +BreakMock serves cached bytes and renders templates in one pass. + +Throughput, requests per second, journal disabled (Go ÷ Java in brackets): + +| Workload | 100 KiB Java | 100 KiB Go | 1 MiB Java | 1 MiB Go | 10 MiB Java | 10 MiB Go | +| --- | ---: | ---: | ---: | ---: | ---: | ---: | +| jsonBody | 8,234 | 57,429 (7.0×) | 1,049 | 10,502 (10.0×) | 55 | 862 (15.7×) | +| body | 26,370 | 54,273 (2.1×) | 2,774 | 10,357 (3.7×) | 260 | 840 (3.2×) | +| bodyFileName | 13,966 | 54,505 (3.9×) | 3,333 | 10,493 (3.1×) | 283 | 845 (3.0×) | +| Template | 21,885 | 34,526 (1.6×) | 2,507 | 11,386 (4.5×) | 145 | 828 (5.7×) | +| Template file | 16,564 | 33,245 (2.0×) | 2,487 | 11,005 (4.4×) | 165 | 828 (5.0×) | +| Template + jsonPath | 21,136 | 28,312 (1.3×) | 2,579 | 11,275 (4.4×) | 181 | 834 (4.6×) | +| jsonBody, gzip | 8,245 | 87,070 (10.6×) | 971 | 74,192 (76.4×) | 75 | 15,675 (208.4×) | + +Server CPU per request, µs, journal disabled (Go saving in brackets): + +| Workload | 100 KiB Java | 100 KiB Go | 1 MiB Java | 1 MiB Go | 10 MiB Java | 10 MiB Go | +| --- | ---: | ---: | ---: | ---: | ---: | ---: | +| jsonBody | 1,013 | 83 (−92%) | 9,146 | 270 (−97%) | 124,868 | 1,980 (−98%) | +| body | 318 | 81 (−75%) | 2,882 | 281 (−90%) | 31,667 | 2,056 (−94%) | +| bodyFileName | 648 | 89 (−86%) | 2,223 | 283 (−87%) | 24,165 | 2,025 (−92%) | +| Template | 381 | 152 (−60%) | 3,386 | 488 (−86%) | 47,921 | 2,628 (−95%) | +| Template file | 537 | 161 (−70%) | 3,643 | 506 (−86%) | 50,880 | 2,949 (−94%) | +| Template + jsonPath | 394 | 180 (−54%) | 3,473 | 513 (−85%) | 45,869 | 2,598 (−94%) | +| jsonBody, gzip | 1,198 | 45 (−96%) | 11,135 | 79 (−99%) | 124,458 | 579 (−99.5%) | + +Peak sampled RSS, MiB, journal disabled (highest across rounds): + +| Size | Java | Go | +| --- | ---: | ---: | +| 100 KiB | 2,359–5,486 | 34–42 | +| 1 MiB | 3,055–5,138 | 60–145 | +| 10 MiB | 11,323–12,665 | 436–898 | + +With a 1,000-entry journal at 1 MiB, BreakMock delivered 4.7–86× Java's +throughput and used 90–99% less CPU per request; peak RSS was 2.4–4.0 GiB for +BreakMock (the journal holds 1,000 bodies) versus 9.5–11.8 GiB for Java. The +10 MiB runs disabled the journal, because 1,000 entries would hold ~10 GB per +server. + +Notes: + +- Java's peak RSS approaches its default maximum heap (a quarter of the host's + 48 GB). Its 10 MiB runs also varied most between rounds (for example 100–233 RPS + for templates), consistent with GC pressure near that limit. +- From 1 MiB up, BreakMock's static and template workloads reach about 10 GB/s + of response data through loopback, which appears to be the shared load + generator's limit rather than the server's; compare CPU per request there. +- At 10 MiB, gzip responses are 208× faster because BreakMock serves cached + compressed bytes (bodies up to 16 MiB), while Java compresses every response. + +Raw data: [100 KiB](../testdata/reports/benchmark-large-json.json), +[1 MiB](../testdata/reports/benchmark-large-json-1mib.json) and +[10 MiB](../testdata/reports/benchmark-large-json-10mib.json), each with the +source commit and binary and JAR hashes. + +## What was slow + +| Cost | Where | Fix | +| --- | --- | --- | +| Templates of 64 KiB or more were never cached. Each request re-lexed the whole body with raymond's regexp lexer, which is roughly quadratic (≈14 ms per 100 KiB). | `template.go`, `template_plan.go` | Both template caches are now limited by total cached source size (64 MiB, 1,024 entries), not by the size of one template. | +| Every full-evaluator render ran `strings.Contains(source, helper)` for ~70 helper names, scanning the body ~70 times per request. | `renderTemplateContext` | Each cached template records which helper names its source mentions on the first render and reuses that set. | +| `jsonBody` was re-encoded on every request. The stored `json.RawMessage` was validated, compacted and then copied, although `DecodeDocument` already stores the compact wire form. | `ServeHTTP` | The stored bytes are served directly. | +| Gzip (zlib through cgo) re-compressed the same static body on every request. | `ServeHTTP` | Bodies that are not rendered as templates use a cache of compressed output, keyed by content (1 KiB–16 MiB bodies, 64 MiB budget, cleared when full). A changed file or mapping gives a new key, so a stale compressed body is never served. | +| Each journaled response was copied to a string and to base64 (≈2.3× the body size) on the request path. | `Store.RecordServed` | One owned copy is kept. `body` and `bodyAsBase64` are encoded when the journal is read (`journalText`, `journalBase64`). | +| `bodyFileName` called `os.OpenRoot` and opened the file on every request. Under concurrency these opens contend in the kernel (≈24 µs per request with 14 workers). | `resolveBodyEntity` | File contents are cached. A cached body is used only while a `stat` of its path reports the same file, size, mtime **and ctime**. Cache misses still read through `os.Root`, so paths cannot escape `__files`. | +| The body was copied 3–4 times per templated request: string→bytes, the entity's text conversion, Handlebars' `fmt.Sprintf("%s")` and `[]byte` conversion, and `Buffer.String()`. | `entity.go`, `internal/handlebars` | Read-only views and a `strings.Builder` replace these copies. Allocation for the full evaluator fell from 784 KB to 123 KB per request. | + +The last row matters most for the full Handlebars evaluator with the journal +off. There the live heap is only a few MiB, so at `GOGC=100` the collector runs +after every few requests. Before the copy reduction, optimized BreakMock reached +only 0.78× Java's throughput on `templateHelper`; after it, BreakMock was faster +than Java (1.34× in the final run above). + +Two GC policies were also measured: a fixed `GOGC=400` and a dynamic minimum heap +goal. Neither was adopted. Both recovered throughput, but RSS rose from ~40 MiB to +370–830 MiB, and the dynamic goal was unstable while the heap was growing. +Deployments that prefer throughput to memory can still set `GOGC` or +`GOMEMLIMIT`. + +Ctime cannot be set by `cp -p`, `rsync -t` or `touch`, so a same-size in-place +rewrite with a restored mtime is still detected. `TestBodyFileChangesAreServed` +covers this case, an atomic rename, deletion and a symlink that is retargeted +outside `__files`. That test fails if the ctime comparison is removed. Body files +are not cached on platforms other than Linux and macOS, because ctime is not +available there. + +## Compatibility verification + +- `python3 scripts/verify.py --jar wiremock.jar` makes 20 differential suite runs + against the pinned JAR (19 suites, one also without a journal), on the final + code. All 20 pass. The binary-mismatch diagnostic, whose Java output contains a + random JVM object identity, is compared with that token masked (see + [COMPATIBILITY.md](COMPATIBILITY.md#byte-comparison-boundaries)). +- In the benchmark, every served response was compared byte-for-byte with Java's. +- Journal events were also compared with Java's (ids, timings and client details + removed). Static responses matched. Two differences remain, and both exist + unchanged in BreakMock before this work: + - For templated responses, Java journals the rendered body in + `responseDefinition`; BreakMock journals the template source. + - For gzip responses, Java journals the uncompressed body without + `Content-Encoding`; BreakMock journals the compressed bytes. +- `scripts/template_differential.py --pad 80000 --repeat 3` reruns all 429 + template cases inside 80 KB templates, 3 requests each: 429/429 identical to + Java. `scripts/dynamic_template_differential.py` (238 checks) confirms against + Java that responses still change with every request and every edit: + per-request values, random and time helpers, mapping, body file and jsonBody + edits (with gzip), and journal entries under concurrency. The same checks fail + identically on BreakMock before this work, so no regression was found. +- `go test -race ./...` passes. The cgo-free build's tests also pass (gzip cases + are skipped because that build cannot produce WireMock's gzip bytes). + +## In-process benchmark + +`BenchmarkLargeJSONResponse` (in `pkg/breakmock`) calls `ServeHTTP` directly with a +discarding writer. This isolates server work from networking. Median of 5 runs: + +| Workload | Journal | Before µs/op | Optimized µs/op | Speedup | Before B/op | Optimized B/op | +| --- | --- | ---: | ---: | ---: | ---: | ---: | +| jsonBody | off | 141.3 | 2.0 | 71× | 248,466 | 6,666 | +| body | off | 13.1 | 2.0 | 7× | 113,350 | 6,669 | +| bodyFileName | off | 34.7 | 3.9 | 9× | 114,191 | 7,456 | +| templateBody | off | 13,908 | 14.4 | 967× | 780,593 | 113,993 | +| templateFile | off | 13,872 | 16.0 | 868× | 780,570 | 114,935 | +| templateHelper | off | 13,723 | 20.4 | 672× | 784,350 | 123,299 | +| jsonBodyGzip | off | 499.0 | 3.9 | 128× | 359,156 | 6,724 | +| jsonBody | on | 179.0 | 8.4 | 21× | 721,350 | 120,312 | +| body | on | 53.0 | 8.4 | 6× | 611,842 | 120,312 | +| bodyFileName | on | 79.7 | 11.0 | 7× | 612,668 | 121,097 | +| templateBody | on | 13,971 | 19.1 | 733× | 1,270,250 | 227,536 | +| templateFile | on | 14,155 | 21.7 | 651× | 1,270,237 | 228,482 | +| templateHelper | on | 14,072 | 26.0 | 540× | 1,271,948 | 235,971 | +| jsonBodyGzip | on | 491.2 | 8.3 | 59× | 377,026 | 20,455 | + +## Workloads + +Each workload serves the same deterministic order listing (~100 KiB, with nested +objects, numbers, `é` and `<`), as follows: + +- `jsonBody`, `body`, `bodyFileName`: the static document inline as JSON, as a + string, or from `__files`. +- `templateBody`, `templateFile`: the document with + `{{request.query.customer}}` and `{{request.headers.X-Request-Id}}`. This takes + the optimized straight-line template plan. +- `templateHelper`: a POST that uses `{{jsonPath request.body '$.customer'}}`. + This runs the full Handlebars evaluator. +- `jsonBodyGzip`: `jsonBody` with `Accept-Encoding: gzip`. + +## Reproduce + +```sh +# In-process (both checkouts need json_response_benchmark_test.go). +go test ./pkg/breakmock -run '^$' -bench 'LargeJSONResponse/.*/100KiB' -count=5 + +# End to end. List Java first so its responses are the byte reference. +# Add --size 1048576 or --size 10485760 --journal disabled for the scaling runs. +curl -fL https://repo.maven.apache.org/maven2/org/wiremock/wiremock-standalone/4.0.0-beta.40/wiremock-standalone-4.0.0-beta.40.jar -o /tmp/wiremock.jar +git worktree add /tmp/bm-baseline 51ac179 +(cd /tmp/bm-baseline && go build -trimpath -o /tmp/breakmock-baseline ./cmd/breakmock) +go build -trimpath -o /tmp/breakmock-optimized ./cmd/breakmock +python3 scripts/json_benchmark.py --binary java=/tmp/wiremock.jar \ + --binary go-baseline=/tmp/breakmock-baseline --binary go-optimized=/tmp/breakmock-optimized \ + --rounds 3 --duration 5s --warmup 2s --journal-check report \ + --output testdata/reports/benchmark-large-json.json +``` + +`--journal-check report` records the two known journal differences instead of +stopping the run. Between BreakMock builds, use the default `strict` mode. + +Raw data: [end-to-end report](../testdata/reports/benchmark-large-json.json) +(including executable and JAR hashes, every round and the journal differences) +and [Go benchmark output](../testdata/reports/benchmark-large-json-go.txt). diff --git a/internal/handlebars/eval.go b/internal/handlebars/eval.go index 053be4d..4f658b8 100644 --- a/internal/handlebars/eval.go +++ b/internal/handlebars/eval.go @@ -2,7 +2,6 @@ package raymond import ( - "bytes" "fmt" "reflect" "strconv" @@ -803,13 +802,13 @@ func (v *evalVisitor) wasFuncCall(node *ast.Expression) bool { func (v *evalVisitor) VisitProgram(node *ast.Program) interface{} { v.at(node) - buf := new(bytes.Buffer) + // BreakMock modification: a strings.Builder avoids copying each part to + // []byte and copying the whole result again, which matters for large bodies. + var buf strings.Builder for _, n := range node.Body { if str := Str(n.Accept(v)); str != "" { - if _, err := buf.Write([]byte(str)); err != nil { - v.errPanic(err) - } + buf.WriteString(str) } } diff --git a/internal/handlebars/string.go b/internal/handlebars/string.go index 0feaa46..f7c0389 100644 --- a/internal/handlebars/string.go +++ b/internal/handlebars/string.go @@ -54,6 +54,9 @@ func strValue(value reflect.Value) string { result = fmt.Sprintf("%d", ival) case reflect.Float32, reflect.Float64: result = strconv.FormatFloat(val.Float(), 'f', -1, 64) + case reflect.String: + // BreakMock modification: same result as Sprintf("%s") without copying. + result = val.String() case reflect.Invalid: result = "" default: diff --git a/pkg/breakmock/admin_json.go b/pkg/breakmock/admin_json.go index 0bc843a..0f32682 100644 --- a/pkg/breakmock/admin_json.go +++ b/pkg/breakmock/admin_json.go @@ -102,6 +102,14 @@ func adminJSONValue(b *bytes.Buffer, v any, depth int, context string, order *ad b.WriteByte('}') return nil } + switch x := v.(type) { + case journalText: + adminJSONString(b, x.String()) + return nil + case journalBase64: + adminJSONString(b, x.String()) + return nil + } rv := reflect.ValueOf(v) if rv.IsValid() && (rv.Kind() == reflect.Slice || rv.Kind() == reflect.Array) { if data, ok := v.([]byte); ok { diff --git a/pkg/breakmock/body_file_cache.go b/pkg/breakmock/body_file_cache.go new file mode 100644 index 0000000..189af3c --- /dev/null +++ b/pkg/breakmock/body_file_cache.go @@ -0,0 +1,96 @@ +// Copyright 2026 Breaking-IT. Licensed under the Apache License, Version 2.0. +package breakmock + +import ( + "bytes" + "os" + "path/filepath" + "sync" +) + +// Body files are re-read for every request in WireMock, and concurrent opens +// contend in the kernel. A cached body is reused only while a stat of its path +// still reports the same file, size, modification and change time; the change +// time cannot be preserved by copying tools, so in-place rewrites are detected. +// Every read still goes through os.Root, so paths cannot escape __files. +const ( + bodyFileCacheMaxFile = 16 << 20 + bodyFileCacheBytes = 64 << 20 +) + +type bodyFileVersion struct { + info os.FileInfo + change int64 +} + +type bodyFileEntry struct { + data []byte + version bodyFileVersion +} + +var bodyFileCache = struct { + sync.RWMutex + entries map[string]*bodyFileEntry + bytes int +}{entries: map[string]*bodyFileEntry{}} + +func bodyFileVersionOf(info os.FileInfo) (bodyFileVersion, bool) { + change, ok := fileChangeTime(info) + return bodyFileVersion{info, change}, ok && info.Mode().IsRegular() +} + +func (v bodyFileVersion) matches(info os.FileInfo) bool { + change, ok := fileChangeTime(info) + return ok && change == v.change && os.SameFile(v.info, info) && info.Size() == v.info.Size() && info.ModTime().Equal(v.info.ModTime()) +} + +// readBodyFile returns the contents of name within dir; callers must not modify them. +func readBodyFile(dir, name string) ([]byte, error) { + key := dir + "\x00" + name + bodyFileCache.RLock() + entry := bodyFileCache.entries[key] + bodyFileCache.RUnlock() + if entry != nil { + if info, err := os.Stat(filepath.Join(dir, name)); err == nil && entry.version.matches(info) { + return entry.data, nil + } + } + files, err := os.OpenRoot(dir) + if err != nil { + return nil, err + } + defer files.Close() + file, err := files.Open(name) + if err != nil { + return nil, err + } + defer file.Close() + info, err := file.Stat() + if err != nil { + return nil, err + } + var buffer bytes.Buffer + if info.Size() > 0 && info.Size() <= bodyFileCacheMaxFile { + buffer.Grow(int(info.Size()) + 1) + } + if _, err = buffer.ReadFrom(file); err != nil { + return nil, err + } + data := buffer.Bytes() + // The version is taken before reading, so a concurrent write changes it and + // the next request reads the file again. + if version, ok := bodyFileVersionOf(info); ok && len(data) <= bodyFileCacheMaxFile { + bodyFileCache.Lock() + if old := bodyFileCache.entries[key]; old != nil { + bodyFileCache.bytes -= len(old.data) + } + if bodyFileCache.bytes+len(data) > bodyFileCacheBytes { + clear(bodyFileCache.entries) + bodyFileCache.bytes = 0 + } + bodyFileCache.entries[key] = &bodyFileEntry{data: data, version: version} + bodyFileCache.bytes += len(data) + bodyFileCache.Unlock() + } + return data, nil +} diff --git a/pkg/breakmock/body_file_cache_test.go b/pkg/breakmock/body_file_cache_test.go new file mode 100644 index 0000000..6d95a33 --- /dev/null +++ b/pkg/breakmock/body_file_cache_test.go @@ -0,0 +1,83 @@ +// Copyright 2026 Breaking-IT. Licensed under the Apache License, Version 2.0. +package breakmock + +import ( + "net/http/httptest" + "os" + "path/filepath" + "runtime" + "testing" + "time" +) + +func TestBodyFileChangesAreServed(t *testing.T) { + root := t.TempDir() + files := filepath.Join(root, "__files") + os.MkdirAll(files, 0o755) + path := filepath.Join(files, "body.json") + os.WriteFile(path, []byte(`{"v":1}`), 0o644) + os.WriteFile(filepath.Join(root, "outside.json"), []byte(`{"secret":1}`), 0o644) + s, err := NewServer(Options{RootDir: root, DisableJournal: true}) + if err != nil { + t.Fatal(err) + } + for _, mapping := range []string{ + `{"request":{"url":"/body"},"response":{"status":200,"bodyFileName":"body.json"}}`, + `{"request":{"url":"/link"},"response":{"status":200,"bodyFileName":"link.json"}}`, + } { + if _, err = s.Store.AddMappingDocument([]byte(mapping)); err != nil { + t.Fatal(err) + } + } + get := func(url string) (int, string) { + w := httptest.NewRecorder() + s.ServeHTTP(w, httptest.NewRequest("GET", url, nil)) + return w.Code, w.Body.String() + } + expect := func(want string) { + t.Helper() + for i := 0; i < 2; i++ { + if code, body := get("/body"); code != 200 || body != want { + t.Fatalf("got %d %q, want %q", code, body, want) + } + } + } + expect(`{"v":1}`) + + // Same size, rewritten in place, with the modification time restored. + info, _ := os.Stat(path) + time.Sleep(10 * time.Millisecond) + os.WriteFile(path, []byte(`{"v":2}`), 0o644) + os.Chtimes(path, info.ModTime(), info.ModTime()) + expect(`{"v":2}`) + + // Atomically replaced by rename. + os.WriteFile(path+".tmp", []byte(`{"v":3}`), 0o644) + os.Rename(path+".tmp", path) + expect(`{"v":3}`) + + // Removed: served as WireMock's missing file error. + os.Remove(path) + if code, _ := get("/body"); code != 500 { + t.Fatalf("removed file: status %d", code) + } + os.WriteFile(path, []byte(`{"v":4}`), 0o644) + expect(`{"v":4}`) + + // A link that later escapes __files is rejected, not served from the cache. + if runtime.GOOS == "windows" { + return + } + link := filepath.Join(files, "link.json") + if err = os.Symlink("body.json", link); err != nil { + t.Skip(err) + } + if code, body := get("/link"); code != 200 || body != `{"v":4}` { + t.Fatalf("link inside root: %d %q", code, body) + } + os.Remove(link) + os.Symlink(filepath.Join(root, "outside.json"), link) + if code, body := get("/link"); code != 500 { + t.Fatalf("escaping link served %d %q", code, body) + } +} diff --git a/pkg/breakmock/body_file_change_darwin.go b/pkg/breakmock/body_file_change_darwin.go new file mode 100644 index 0000000..21386aa --- /dev/null +++ b/pkg/breakmock/body_file_change_darwin.go @@ -0,0 +1,15 @@ +// Copyright 2026 Breaking-IT. Licensed under the Apache License, Version 2.0. +package breakmock + +import ( + "os" + "syscall" +) + +func fileChangeTime(info os.FileInfo) (int64, bool) { + stat, ok := info.Sys().(*syscall.Stat_t) + if !ok { + return 0, false + } + return stat.Ctimespec.Nano(), true +} diff --git a/pkg/breakmock/body_file_change_linux.go b/pkg/breakmock/body_file_change_linux.go new file mode 100644 index 0000000..1ee3dda --- /dev/null +++ b/pkg/breakmock/body_file_change_linux.go @@ -0,0 +1,15 @@ +// Copyright 2026 Breaking-IT. Licensed under the Apache License, Version 2.0. +package breakmock + +import ( + "os" + "syscall" +) + +func fileChangeTime(info os.FileInfo) (int64, bool) { + stat, ok := info.Sys().(*syscall.Stat_t) + if !ok { + return 0, false + } + return stat.Ctim.Nano(), true +} diff --git a/pkg/breakmock/body_file_change_other.go b/pkg/breakmock/body_file_change_other.go new file mode 100644 index 0000000..84c4c0c --- /dev/null +++ b/pkg/breakmock/body_file_change_other.go @@ -0,0 +1,9 @@ +//go:build !darwin && !linux + +// Copyright 2026 Breaking-IT. Licensed under the Apache License, Version 2.0. +package breakmock + +import "os" + +// Without a change time, in-place rewrites cannot be detected; body files are not cached. +func fileChangeTime(os.FileInfo) (int64, bool) { return 0, false } diff --git a/pkg/breakmock/compression_cache.go b/pkg/breakmock/compression_cache.go new file mode 100644 index 0000000..9148f08 --- /dev/null +++ b/pkg/breakmock/compression_cache.go @@ -0,0 +1,49 @@ +// Copyright 2026 Breaking-IT. Licensed under the Apache License, Version 2.0. +package breakmock + +import "sync" + +// Compressing a large static body costs far more than looking it up, and wire +// gzip output depends only on the input bytes. Entries are keyed by content, so +// a changed body file or mapping can never be served a stale compressed form. +const ( + gzipCacheMinBytes = 1 << 10 + gzipCacheMaxBytes = 16 << 20 + gzipCacheBytes = 64 << 20 +) + +var gzipCache = struct { + sync.RWMutex + entries map[string][]byte + bytes int +}{entries: map[string][]byte{}} + +// cachedWireGzip returns wireGzip(data); callers must not modify the result. +func cachedWireGzip(data []byte) ([]byte, error) { + if len(data) < gzipCacheMinBytes || len(data) > gzipCacheMaxBytes { + return wireGzip(data) + } + gzipCache.RLock() + compressed, ok := gzipCache.entries[string(data)] + gzipCache.RUnlock() + if ok { + return compressed, nil + } + compressed, err := wireGzip(data) + if err != nil { + return nil, err + } + size := len(data) + len(compressed) + gzipCache.Lock() + if gzipCache.bytes+size > gzipCacheBytes { + // Start a new generation rather than tracking recency on every hit. + clear(gzipCache.entries) + gzipCache.bytes = 0 + } + if _, exists := gzipCache.entries[string(data)]; !exists { + gzipCache.entries[string(data)] = compressed + gzipCache.bytes += size + } + gzipCache.Unlock() + return compressed, nil +} diff --git a/pkg/breakmock/diagnostics.go b/pkg/breakmock/diagnostics.go index d56d78a..74b5c20 100644 --- a/pkg/breakmock/diagnostics.go +++ b/pkg/breakmock/diagnostics.go @@ -10,6 +10,8 @@ import ( "encoding/json" "fmt" "github.com/ohler55/ojg/jp" + "math" + "math/rand/v2" "net/http" "net/url" "sort" @@ -232,7 +234,7 @@ func (s *Server) renderDiagnostic(m Mapping, req Request, width int) string { actual = "\n" + actual if name == "binaryEqualTo" { expected = v - actual = base64.StdEncoding.EncodeToString(req.Body) + actual = javaByteArrayIdentity() } if name == "matchesJsonPath" || name == "matchesXPath" { expected = v @@ -381,3 +383,11 @@ func prettyDiagnosticJSON(s string) string { } return b.String() } + +// javaByteArrayIdentity mirrors how WireMock renders the actual body for a +// binary mismatch: Java's default toString of a fresh byte[], "[B@" followed by +// the array's identity hash in hex. That hash is a per-object JVM value, never +// derived from the request, so it is random here as it is in Java. +func javaByteArrayIdentity() string { + return "[B@" + strconv.FormatInt(int64(rand.Int32N(math.MaxInt32)+1), 16) +} diff --git a/pkg/breakmock/diagnostics_test.go b/pkg/breakmock/diagnostics_test.go index f1abc3b..1a0b6af 100644 --- a/pkg/breakmock/diagnostics_test.go +++ b/pkg/breakmock/diagnostics_test.go @@ -4,6 +4,7 @@ import ( "bytes" "net/http/httptest" "os" + "regexp" "testing" ) @@ -40,3 +41,18 @@ func TestTemplateErrorHasExactPlainBody(t *testing.T) { t.Fatalf("%v %s", w.Result(), w.Body.String()) } } + +func TestBinaryMismatchUsesJavaByteArrayIdentity(t *testing.T) { + shape := regexp.MustCompile(`^\[B@[1-9a-f][0-9a-f]{0,7}$`) + seen := map[string]bool{} + for i := 0; i < 50; i++ { + identity := javaByteArrayIdentity() + if !shape.MatchString(identity) { + t.Fatalf("identity %q does not have Java's byte[] toString shape", identity) + } + seen[identity] = true + } + if len(seen) < 45 { + t.Fatalf("identities should vary per call like JVM identity hashes, got %d distinct of 50", len(seen)) + } +} diff --git a/pkg/breakmock/entity.go b/pkg/breakmock/entity.go index f94d96a..82950e3 100644 --- a/pkg/breakmock/entity.go +++ b/pkg/breakmock/entity.go @@ -9,9 +9,10 @@ import ( "golang.org/x/text/encoding/charmap" "golang.org/x/text/encoding/ianaindex" "golang.org/x/text/encoding/unicode" - "os" "path/filepath" "strings" + "unicode/utf8" + "unsafe" ) type resolvedEntity struct { @@ -71,6 +72,9 @@ func (e resolvedEntity) text() (string, error) { return "", err } if codec == nil { + if utf8.Valid(e.data) { + return readOnlyString(e.data), nil + } return strings.ToValidUTF8(string(e.data), "\ufffd"), nil } data, err := codec.NewDecoder().Bytes(e.data) @@ -83,7 +87,7 @@ func resolveBodyEntity(value any, root string) (result resolvedEntity, resultErr } }() if text, ok := value.(string); ok { - result.data = []byte(text) + result.data = readOnlyBytes(text) return result, nil } object, ok := value.(map[string]any) @@ -128,11 +132,8 @@ func resolveBodyEntity(value any, root string) (result resolvedEntity, resultErr } if fromFile { result.fromFile = true - files, err := os.OpenRoot(filepath.Join(root, "__files")) - if err == nil { - result.data, err = files.ReadFile(name) - files.Close() - } + var err error + result.data, err = readBodyFile(filepath.Join(root, "__files"), name) if err == nil { return result, nil } @@ -145,3 +146,19 @@ func resolveBodyEntity(value any, root string) (result resolvedEntity, resultErr } return result, nil } + +// readOnlyBytes and readOnlyString convert without copying. Resolved bodies +// (inline text, cached body files, stored jsonBody, rendered templates) are only +// written, compressed, copied or sliced; they are never modified in place. +func readOnlyBytes(s string) []byte { + if s == "" { + return []byte{} + } + return unsafe.Slice(unsafe.StringData(s), len(s)) +} +func readOnlyString(b []byte) string { + if len(b) == 0 { + return "" + } + return unsafe.String(&b[0], len(b)) +} diff --git a/pkg/breakmock/journal_storage_test.go b/pkg/breakmock/journal_storage_test.go index 783051b..82489a2 100644 --- a/pkg/breakmock/journal_storage_test.go +++ b/pkg/breakmock/journal_storage_test.go @@ -2,8 +2,12 @@ package breakmock import ( + "encoding/base64" + "encoding/json" "fmt" + "net/http/httptest" "slices" + "strings" "testing" ) @@ -71,3 +75,50 @@ func TestJournalWrapReconfigurationAndSnapshotIsolation(t *testing.T) { t.Fatal("overwrite mutated prior snapshot") } } + +func TestJournalServesLoggedResponseBodies(t *testing.T) { + s, err := NewServer(Options{RootDir: t.TempDir()}) + if err != nil { + t.Fatal(err) + } + body := strings.Repeat(`{"name":"Zoë ","n":1},`, 100) + mapping, _ := json.Marshal(map[string]any{"request": map[string]any{"urlPath": "/logged"}, "response": map[string]any{"status": 200, "headers": map[string]any{"Content-Type": "application/json"}, "body": body}}) + if _, err = s.Store.AddMappingDocument(mapping); err != nil { + t.Fatal(err) + } + if !gzipAvailable() { + t.Skip("gzip responses require a cgo build") + } + plain := httptest.NewRecorder() + s.ServeHTTP(plain, httptest.NewRequest("GET", "/logged", nil)) + compressedRequest := httptest.NewRequest("GET", "/logged?gzip", nil) + compressedRequest.Header.Set("Accept-Encoding", "gzip") + compressed := httptest.NewRecorder() + s.ServeHTTP(compressed, compressedRequest) + if plain.Body.String() != body || compressed.Header().Get("Content-Encoding") != "gzip" { + t.Fatal("unexpected served responses") + } + admin := httptest.NewRecorder() + s.ServeHTTP(admin, httptest.NewRequest("GET", "/__admin/requests", nil)) + var journal struct { + Requests []struct { + Response struct { + Body string `json:"body"` + BodyAsBase64 string `json:"bodyAsBase64"` + } `json:"response"` + } `json:"requests"` + } + if err = json.Unmarshal(admin.Body.Bytes(), &journal); err != nil || len(journal.Requests) != 2 { + t.Fatal(err, admin.Body.String()) + } + // Newest first: the gzip response, then the plain response. + for i, served := range [][]byte{compressed.Body.Bytes(), plain.Body.Bytes()} { + logged := journal.Requests[i].Response + if logged.BodyAsBase64 != base64.StdEncoding.EncodeToString(served) || (i == 1 && logged.Body != body) { + t.Fatalf("logged response %d differs from served bytes", i) + } + } + if !strings.Contains(admin.Body.String(), `"body" : "{\"name\":\"Zoë \"`) { + t.Fatal("logged text body is not serialized with admin escaping") + } +} diff --git a/pkg/breakmock/json_response_benchmark_test.go b/pkg/breakmock/json_response_benchmark_test.go new file mode 100644 index 0000000..17bff05 --- /dev/null +++ b/pkg/breakmock/json_response_benchmark_test.go @@ -0,0 +1,225 @@ +// Copyright 2026 Breaking-IT. Licensed under the Apache License, Version 2.0. +package breakmock + +import ( + "bytes" + "encoding/json" + "fmt" + "io" + "net/http" + "net/http/httptest" + "os" + "path/filepath" + "strings" + "sync" + "testing" +) + +// largeJSONDocument returns a deterministic order listing of roughly size bytes. +// When templated, a few fields echo request values, as typical dynamic stubs do. +func largeJSONDocument(size int, template string) string { + var b strings.Builder + b.WriteString(`{"customer":`) + switch template { + case "plan": + b.WriteString(`"{{request.query.customer}}"`) + case "helper": + b.WriteString(`"{{jsonPath request.body '$.customer'}}"`) + default: + b.WriteString(`"C-1001"`) + } + b.WriteString(`,"currency":"EUR","orders":[`) + for i := 0; b.Len() < size; i++ { + if i > 0 { + b.WriteByte(',') + } + fmt.Fprintf(&b, `{"id":%d,"status":"SHIPPED","total":%d.%02d,"note":"Fragile é with care","items":[{"sku":"SKU-%05d","qty":%d,"price":19.95,"tags":["a","b"]},{"sku":"SKU-%05d","qty":1,"price":5.5,"tags":[]}],"address":{"street":"Main %d","city":"Amsterdam","zip":"1011AB"}}`, + i, i*7%1000, i%100, i, i%5+1, i+1, i) + } + b.WriteString(`],"requestId":`) + if template != "" { + b.WriteString(`"{{request.headers.X-Request-Id}}"`) + } else { + b.WriteString(`"r-1"`) + } + b.WriteString(`}`) + return b.String() +} + +type jsonBenchCase struct { + name string + mapping func(doc string) string + request func() *http.Request + files bool + template string +} + +// gzipAvailable reports whether this build can produce WireMock's gzip bytes (cgo only). +func gzipAvailable() bool { _, err := wireGzip(nil); return err == nil } + +func jsonBenchCases() []jsonBenchCase { + get := func() *http.Request { + r := httptest.NewRequest("GET", "/orders?customer=C-1001", nil) + r.Header.Set("X-Request-Id", "r-1") + return r + } + quote := func(s string) string { b, _ := json.Marshal(s); return string(b) } + cases := []jsonBenchCase{ + {name: "jsonBody", request: get, mapping: func(doc string) string { + return `{"request":{"method":"GET","urlPath":"/orders"},"response":{"status":200,"headers":{"Content-Type":"application/json"},"jsonBody":` + doc + `}}` + }}, + {name: "body", request: get, mapping: func(doc string) string { + return `{"request":{"method":"GET","urlPath":"/orders"},"response":{"status":200,"headers":{"Content-Type":"application/json"},"body":` + quote(doc) + `}}` + }}, + {name: "bodyFileName", files: true, request: get, mapping: func(string) string { + return `{"request":{"method":"GET","urlPath":"/orders"},"response":{"status":200,"headers":{"Content-Type":"application/json"},"bodyFileName":"orders.json"}}` + }}, + {name: "templateBody", template: "plan", request: get, mapping: func(doc string) string { + return `{"request":{"method":"GET","urlPath":"/orders"},"response":{"status":200,"headers":{"Content-Type":"application/json"},"body":` + quote(doc) + `,"transformers":["response-template"]}}` + }}, + {name: "templateFile", template: "plan", files: true, request: get, mapping: func(string) string { + return `{"request":{"method":"GET","urlPath":"/orders"},"response":{"status":200,"headers":{"Content-Type":"application/json"},"bodyFileName":"orders.json","transformers":["response-template"]}}` + }}, + {name: "templateHelper", template: "helper", request: func() *http.Request { + r := httptest.NewRequest("POST", "/orders", strings.NewReader(`{"customer":"C-1001"}`)) + r.Header.Set("Content-Type", "application/json") + r.Header.Set("X-Request-Id", "r-1") + return r + }, mapping: func(doc string) string { + return `{"request":{"method":"POST","urlPath":"/orders"},"response":{"status":200,"headers":{"Content-Type":"application/json"},"body":` + quote(doc) + `,"transformers":["response-template"]}}` + }}, + {name: "jsonBodyGzip", request: func() *http.Request { + r := get() + r.Header.Set("Accept-Encoding", "gzip") + return r + }, mapping: func(doc string) string { + return `{"request":{"method":"GET","urlPath":"/orders"},"response":{"status":200,"headers":{"Content-Type":"application/json"},"jsonBody":` + doc + `}}` + }}, + } + if !gzipAvailable() { + cases = cases[:len(cases)-1] + } + return cases +} + +func newJSONBenchServer(tb testing.TB, c jsonBenchCase, size int, journal bool) (*Server, []byte) { + root := tb.TempDir() + doc := largeJSONDocument(size, c.template) + if c.files { + os.MkdirAll(filepath.Join(root, "__files"), 0o755) + if e := os.WriteFile(filepath.Join(root, "__files", "orders.json"), []byte(doc), 0o644); e != nil { + tb.Fatal(e) + } + } + s, e := NewServer(Options{RootDir: root, DisableJournal: !journal, MaxJournalEntries: 1000}) + if e != nil { + tb.Fatal(e) + } + if _, e = s.Store.AddMappingDocument([]byte(c.mapping(doc))); e != nil { + tb.Fatal(e) + } + w := httptest.NewRecorder() + s.ServeHTTP(w, c.request()) + if w.Code != 200 { + tb.Fatalf("%s: status %d %s", c.name, w.Code, w.Body.String()) + } + return s, w.Body.Bytes() +} + +// TestLargeJSONResponses pins the body of each benchmark workload so +// optimizations cannot change served bytes. +func TestLargeJSONResponses(t *testing.T) { + for _, c := range jsonBenchCases() { + for _, journal := range []bool{false, true} { + s, first := newJSONBenchServer(t, c, 100<<10, journal) + expected := []byte(largeJSONDocument(100<<10, "")) + if strings.HasSuffix(c.name, "Gzip") { + if !bytes.HasPrefix(first, []byte{0x1f, 0x8b}) { + t.Fatalf("%s: response not gzip", c.name) + } + expected, _ = wireGzip(mustCompactJSON(t, expected)) + } else if c.name == "jsonBody" { + expected = mustCompactJSON(t, expected) + } + if !bytes.Equal(first, expected) { + t.Fatalf("%s journal=%v: body differs (%d vs %d bytes)", c.name, journal, len(first), len(expected)) + } + for i := 0; i < 3; i++ { + w := httptest.NewRecorder() + s.ServeHTTP(w, c.request()) + if !bytes.Equal(w.Body.Bytes(), first) { + t.Fatalf("%s: repeated response differs", c.name) + } + } + } + } +} + +// TestLargeJSONResponsesConcurrent renders cached large templates and body files +// from many goroutines, each with its own request values. +func TestLargeJSONResponsesConcurrent(t *testing.T) { + for _, c := range jsonBenchCases() { + if c.template == "" && !c.files { + continue + } + s, _ := newJSONBenchServer(t, c, 100<<10, true) + var wg sync.WaitGroup + for g := 0; g < 8; g++ { + wg.Add(1) + go func() { + defer wg.Done() + for i := 0; i < 20; i++ { + id := fmt.Sprintf("r-%d-%d", g, i) + r := c.request() + r.Header.Set("X-Request-Id", id) + w := httptest.NewRecorder() + s.ServeHTTP(w, r) + want := `"requestId":"r-1"}` + if c.template != "" { + want = `"requestId":"` + id + `"}` + } + if w.Code != 200 || !strings.HasSuffix(w.Body.String(), want) || !strings.HasPrefix(w.Body.String(), `{"customer":"C-1001"`) { + t.Errorf("%s: unexpected response %d ...%s", c.name, w.Code, w.Body.String()[max(0, w.Body.Len()-40):]) + return + } + } + }() + } + wg.Wait() + } +} + +func mustCompactJSON(t *testing.T, data []byte) []byte { + out, e := wireJSON(data) + if e != nil { + t.Fatal(e) + } + return out +} + +type discardResponseWriter struct{ header http.Header } + +func (w *discardResponseWriter) Header() http.Header { return w.header } +func (w *discardResponseWriter) Write(b []byte) (int, error) { return len(b), nil } +func (w *discardResponseWriter) WriteHeader(int) {} + +func BenchmarkLargeJSONResponse(b *testing.B) { + for _, size := range []int{100 << 10, 1 << 20} { + for _, journal := range []bool{false, true} { + for _, c := range jsonBenchCases() { + name := fmt.Sprintf("%s/%dKiB/journal=%v", c.name, size>>10, journal) + b.Run(name, func(b *testing.B) { + s, body := newJSONBenchServer(b, c, size, journal) + b.SetBytes(int64(len(body))) + b.ReportAllocs() + b.ResetTimer() + for i := 0; i < b.N; i++ { + r := c.request() + s.ServeHTTP(&discardResponseWriter{header: http.Header{}}, r) + io.Copy(io.Discard, r.Body) + } + }) + } + } + } +} diff --git a/pkg/breakmock/messaging.go b/pkg/breakmock/messaging.go index 068afa3..0d95600 100644 --- a/pkg/breakmock/messaging.go +++ b/pkg/breakmock/messaging.go @@ -43,6 +43,10 @@ type MessageStore struct { eventOrders map[string]*adminOrder sequence uint64 changed chan struct{} + // handling is held for reading while an incoming message is processed. A + // reply frame reaches the client before its "sent" and "received" events + // are journaled, so journal reads settle in-flight handling first. + handling sync.RWMutex } func (s *Store) Messaging() *MessageStore { @@ -187,7 +191,14 @@ func (s *MessageStore) Record(id, eventType string, message map[string]any, matc s.mu.Unlock() return eventID } + +// settle waits for incoming messages that are being handled to be journaled. +func (s *MessageStore) settle() { + s.handling.Lock() + s.handling.Unlock() +} func (s *MessageStore) Events() []Mapping { + s.settle() if s.owner.JournalDisabled() { return []Mapping{} } diff --git a/pkg/breakmock/messaging_actions.go b/pkg/breakmock/messaging_actions.go index 604915b..ea4cc75 100644 --- a/pkg/breakmock/messaging_actions.go +++ b/pkg/breakmock/messaging_actions.go @@ -11,6 +11,8 @@ import ( // Incoming executes only the first matching message stub, then journals reception. // Sent events precede reception in insertion order, as in WireMock's handler. func (s *MessageStore) Incoming(id string, message map[string]any) error { + s.handling.RLock() + defer s.handling.RUnlock() channel := s.Channel(id) if channel == nil { return nil diff --git a/pkg/breakmock/messaging_admin.go b/pkg/breakmock/messaging_admin.go index 8463155..635a732 100644 --- a/pkg/breakmock/messaging_admin.go +++ b/pkg/breakmock/messaging_admin.go @@ -346,6 +346,7 @@ func (a *adminHandler) serveMessaging(w http.ResponseWriter, r *http.Request) bo } if p == "/messages" { if r.Method == "DELETE" { + s.settle() s.mu.Lock() s.events = nil s.eventOrders = nil diff --git a/pkg/breakmock/messaging_test.go b/pkg/breakmock/messaging_test.go index 57bb8e0..d300d2d 100644 --- a/pkg/breakmock/messaging_test.go +++ b/pkg/breakmock/messaging_test.go @@ -288,3 +288,41 @@ func TestMessageWaitNegativeCount(t *testing.T) { }) } } + +// A client can read the journal as soon as it receives a reply frame. The +// read must still include the reply's "sent" event and the "received" event. +func TestJournalReadDuringReplyIncludesBothEvents(t *testing.T) { + store := NewStore() + ms := store.Messaging() + h := NewAdminHandler(store, t.TempDir()) + w := httptest.NewRecorder() + h.ServeHTTP(w, httptest.NewRequest("POST", "/__admin/message-mappings", strings.NewReader(`{"trigger":{"type":"message","message":{"body":{"equalTo":"hello"}}},"actions":[{"type":"send","message":{"body":"reply"}}]}`))) + if w.Code != 201 && w.Code != 200 { + t.Fatal(w.Code, w.Body.String()) + } + read := make(chan []Mapping, 1) + readDuringSend := false + send := func(map[string]any) error { + // The frame is on the wire: the client now reads the journal. + go func() { read <- ms.Events() }() + select { + case events := <-read: + readDuringSend = true + read <- events + case <-time.After(50 * time.Millisecond): + } + return nil + } + ch := ms.RegisterChannel("channel", "websocket", Request{Method: "GET", URL: "/ws", Headers: http.Header{}}, send, nil) + if err := ms.Incoming(ch.ID, map[string]any{"body": "hello"}); err != nil { + t.Fatal(err) + } + events := <-read + types := []string{} + for _, e := range events { + types = append(types, bmString(e["eventType"])) + } + if readDuringSend || len(events) != 2 || types[0] != "received" || types[1] != "sent" { + t.Fatalf("journal read completed during the reply (%v) with events %v", readDuringSend, types) + } +} diff --git a/pkg/breakmock/recording.go b/pkg/breakmock/recording.go index b0cdb40..d2d3083 100644 --- a/pkg/breakmock/recording.go +++ b/pkg/breakmock/recording.go @@ -249,7 +249,10 @@ func (a *adminHandler) snapshot(entries []journalEntry, spec map[string]any) (ma if len(rh) > 0 { response["headers"] = rh } - bodyBytes, _ := base64.StdEncoding.DecodeString(bmString(logged["bodyAsBase64"])) + bodyBytes, _ := logged["bodyAsBase64"].(journalBase64) + if encoded, ok := logged["bodyAsBase64"].(string); ok { + bodyBytes, _ = base64.StdEncoding.DecodeString(encoded) + } for k, v := range headers { if strings.EqualFold(k, "Content-Encoding") && strings.EqualFold(fmt.Sprint(v), "gzip") { if reader, err := gzip.NewReader(bytes.NewReader(bodyBytes)); err == nil { diff --git a/pkg/breakmock/server.go b/pkg/breakmock/server.go index 645e5a8..aef8ecd 100644 --- a/pkg/breakmock/server.go +++ b/pkg/breakmock/server.go @@ -21,6 +21,7 @@ import ( "strings" "sync" "time" + "unicode/utf8" ) type Options struct { @@ -150,6 +151,7 @@ func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) { requestURI := r.URL.RequestURI() req := Request{HeaderOrder: headerOrder, Method: r.Method, URL: requestURI, AbsoluteURL: scheme + "://" + r.Host + requestURI, Headers: r.Header.Clone(), Body: decodedBody} req.Headers.Set("Host", r.Host) + decodeLatin1Headers(req.Headers) req.ClientIP, _, _ = net.SplitHostPort(r.RemoteAddr) var selected Mapping var capture *servedResponseWriter @@ -168,7 +170,7 @@ func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) { finished = time.Now() } req.ProcessTimeMillis = max(int64(0), (finished.Sub(processStarted) - waited).Milliseconds()) - eventID = s.Store.RecordServed(req, selected, capture.status, capture.Header(), capture.body.Bytes(), capture.headerOrder) + eventID = s.Store.recordServed(req, selected, capture.status, capture.Header(), capture.body.Bytes(), capture.headerOrder) } if selected != nil { DispatchWebhooks(s.Store, eventID, req, selected, s.options.RootDir) @@ -348,7 +350,12 @@ func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) { entity := resolvedEntity{} switch { case response["jsonBody"] != nil: - out, err = marshalJSON(response["jsonBody"]) + if raw, ok := response["jsonBody"].(json.RawMessage); ok { + // Stored mappings hold jsonBody in its compact wire form (see DecodeDocument). + out = raw + } else { + out, err = marshalJSON(response["jsonBody"]) + } case response["base64Body"] != nil: out, err = base64.StdEncoding.DecodeString(bmString(response["base64Body"])) entity.binary = true @@ -386,6 +393,7 @@ func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) { } entity.data = out disableFileTemplate := params["disableBodyFileTemplating"] == true && entity.fromFile + rendered := false if templated && !disableFileTemplate { source, e := entity.text() if e != nil { @@ -398,7 +406,8 @@ func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) { s.writeTemplateError(w, e, selected) return } - out = []byte(v) + out = readOnlyBytes(v) + rendered = true } } // Avoid Go's automatic content sniffing; WireMock does not infer a type for inline bodies. @@ -406,7 +415,12 @@ func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) { w.Header()["Content-Type"] = nil } if acceptsGzip(r.Header.Get("Accept-Encoding")) && gzipResponseAllowed(r, status, w.Header()) { - compressed, err := wireGzip(out) + compress := wireGzip + if !rendered { + // Static bodies are identical across requests; reuse their compressed form. + compress = cachedWireGzip + } + compressed, err := compress(out) if err != nil { http.Error(w, err.Error(), http.StatusInternalServerError) return @@ -619,6 +633,30 @@ func (w *servedResponseWriter) Hijack() (net.Conn, *bufio.ReadWriter, error) { } func (w *servedResponseWriter) Unwrap() http.ResponseWriter { return w.ResponseWriter } +// decodeLatin1Headers decodes header values in place as Jetty does: each byte +// is one ISO-8859-1 character. Matching, templates and the journal then see the +// same text as WireMock, for example byte 0xE9 as "é" and UTF-8 "é" as "é". +func decodeLatin1Headers(headers http.Header) { + for _, values := range headers { + for i, value := range values { + values[i] = latin1String(value) + } + } +} + +func latin1String(value string) string { + for i := 0; i < len(value); i++ { + if value[i] >= utf8.RuneSelf { + decoded := make([]rune, len(value)) + for j := 0; j < len(value); j++ { + decoded[j] = rune(value[j]) + } + return string(decoded) + } + } + return value +} + func acceptsGzip(value string) bool { for _, part := range strings.Split(value, ",") { p := strings.Split(strings.TrimSpace(part), ";") diff --git a/pkg/breakmock/server_test.go b/pkg/breakmock/server_test.go index ec0ff38..1f7cd43 100644 --- a/pkg/breakmock/server_test.go +++ b/pkg/breakmock/server_test.go @@ -201,3 +201,25 @@ func TestCanonicalJSONEdgeCases(t *testing.T) { } } } + +func TestHeaderBytesAreDecodedAsLatin1(t *testing.T) { + s, _ := NewServer(Options{RootDir: t.TempDir()}) + for _, mapping := range []string{ + `{"request":{"urlPath":"/h"},"response":{"status":200,"body":"[{{request.headers.X-V}}]","transformers":["response-template"]}}`, + `{"priority":1,"request":{"urlPath":"/h","headers":{"X-V":{"equalTo":"é"}}},"response":{"status":200,"body":"matched"}}`, + } { + if _, err := s.Store.AddMappingDocument([]byte(mapping)); err != nil { + t.Fatal(err) + } + } + // Captured from WireMock 4.0.0-beta.40 with raw header bytes. + for raw, want := range map[string]string{"\xe9": "matched", "\xc3\xa9": "[é]", "a\xe9b\xc3\xa9": "[aébé]", "plain": "[plain]"} { + r := httptest.NewRequest("GET", "/h", nil) + r.Header["X-V"] = []string{raw} + w := httptest.NewRecorder() + s.ServeHTTP(w, r) + if w.Body.String() != want { + t.Fatalf("header %q: got %q, want %q", raw, w.Body.String(), want) + } + } +} diff --git a/pkg/breakmock/small_response_benchmark_test.go b/pkg/breakmock/small_response_benchmark_test.go new file mode 100644 index 0000000..8783fbb --- /dev/null +++ b/pkg/breakmock/small_response_benchmark_test.go @@ -0,0 +1,39 @@ +// Copyright 2026 Breaking-IT. Licensed under the Apache License, Version 2.0. +package breakmock + +import ( + "fmt" + "net/http" + "net/http/httptest" + "testing" +) + +// BenchmarkSmallResponse mirrors scripts/benchmark.py: a 17-byte static body and +// a small template, with the journal disabled or capped at 1,000 entries. +func BenchmarkSmallResponse(b *testing.B) { + workloads := map[string]string{ + "static": `{"request":{"method":"GET","urlPath":"/bench"},"response":{"status":200,"body":"Hello, benchmark!","headers":{"Content-Type":"text/plain"}}}`, + "template": `{"request":{"method":"GET","urlPath":"/bench"},"response":{"status":200,"body":"Hello {{request.query.name}}: {{math 2 '+' 3}}","transformers":["response-template"],"headers":{"Content-Type":"text/plain"}}}`, + } + for _, journal := range []bool{false, true} { + for _, name := range []string{"static", "template"} { + b.Run(fmt.Sprintf("%s/journal=%v", name, journal), func(b *testing.B) { + s, _ := NewServer(Options{RootDir: b.TempDir(), DisableJournal: !journal, MaxJournalEntries: 1000}) + if _, err := s.Store.AddMappingDocument([]byte(workloads[name])); err != nil { + b.Fatal(err) + } + request := func() *http.Request { + r := httptest.NewRequest("GET", "/bench?name=Ada", nil) + r.Header.Set("User-Agent", "Go-http-client/1.1") + r.Header.Set("Accept-Encoding", "identity") + return r + } + b.ReportAllocs() + b.ResetTimer() + for i := 0; i < b.N; i++ { + s.ServeHTTP(&discardResponseWriter{header: http.Header{}}, request()) + } + }) + } + } +} diff --git a/pkg/breakmock/store.go b/pkg/breakmock/store.go index 775e65d..9e164f0 100644 --- a/pkg/breakmock/store.go +++ b/pkg/breakmock/store.go @@ -5,6 +5,7 @@ import ( "crypto/rand" "encoding/base64" "encoding/hex" + "encoding/json" "fmt" "net/http" "net/url" @@ -247,6 +248,25 @@ func (s *Store) ResetRequests() { } func (s *Store) Record(r Request, m Mapping, status int) { s.RecordServed(r, m, status, nil, nil) } func (s *Store) RecordServed(r Request, m Mapping, status int, responseHeaders http.Header, responseBody []byte, responseHeaderOrder ...[]string) string { + return s.recordServed(r, m, status, responseHeaders, append([]byte(nil), responseBody...), responseHeaderOrder...) +} + +// journalText and journalBase64 are logged response body views, encoded when +// the journal is read rather than copied twice on every served request. +type journalText []byte +type journalBase64 []byte + +func (b journalText) String() string { return string(b) } +func (b journalBase64) String() string { return base64.StdEncoding.EncodeToString(b) } +func (b journalText) MarshalJSON() ([]byte, error) { + return json.Marshal(b.String()) +} +func (b journalBase64) MarshalJSON() ([]byte, error) { + return json.Marshal(b.String()) +} + +// recordServed takes ownership of responseBody, which must not be modified afterwards. +func (s *Store) recordServed(r Request, m Mapping, status int, responseHeaders http.Header, responseBody []byte, responseHeaderOrder ...[]string) string { s.mu.RLock() disabled := s.journalDisabled s.mu.RUnlock() @@ -322,7 +342,7 @@ func (s *Store) RecordServed(r Request, m Mapping, status int, responseHeaders h event["stubMapping"] = m event["responseDefinition"] = m["response"] } - response := map[string]any{"status": status, "body": string(responseBody), "bodyAsBase64": base64.StdEncoding.EncodeToString(responseBody), "fromProxy": false} + response := map[string]any{"status": status, "body": journalText(responseBody), "bodyAsBase64": journalBase64(responseBody), "fromProxy": false} if len(responseHeaders) > 0 { h := make(map[string]any, len(responseHeaders)) for k, v := range responseHeaders { diff --git a/pkg/breakmock/template.go b/pkg/breakmock/template.go index 41103c8..6139a4f 100644 --- a/pkg/breakmock/template.go +++ b/pkg/breakmock/template.go @@ -14,6 +14,7 @@ import ( "strconv" "strings" "sync" + "sync/atomic" "time" "unicode/utf16" @@ -21,28 +22,71 @@ import ( "github.com/ohler55/ojg/jp" ) +// Template sources are cached by content. Large response bodies are the most +// expensive to lex, so the bound is total cached source size, not a per-source size. +const ( + templateCacheEntries = 1024 + templateCacheBytes = 64 << 20 +) + +// A parsed template and the helper names its source mentions. Helper presence is +// a substring check over the whole source; it is recorded on first render, since +// repeating dozens of scans over a large response body dominates rendering. +type templateCacheEntry struct { + template *raymond.Template + source string + helpers atomic.Pointer[map[string]bool] +} + +// mentions reports whether the source contains a helper name. It returns a +// recorder that the caller publishes after a render registered every helper. +func (e *templateCacheEntry) mentions() (func(string) bool, func()) { + if known := e.helpers.Load(); known != nil { + return func(name string) bool { + found, ok := (*known)[name] + if !ok { + found = strings.Contains(e.source, name) + } + return found + }, func() {} + } + seen := map[string]bool{} + return func(name string) bool { + found := strings.Contains(e.source, name) + seen[name] = found + return found + }, func() { + e.helpers.CompareAndSwap(nil, &seen) + } +} + var templateCache = struct { sync.RWMutex - entries map[string]*raymond.Template -}{entries: make(map[string]*raymond.Template)} + entries map[string]*templateCacheEntry + bytes int +}{entries: make(map[string]*templateCacheEntry)} -func cachedTemplate(source string) (*raymond.Template, error) { +func cachedTemplate(source string) (*raymond.Template, *templateCacheEntry, error) { templateCache.RLock() - t := templateCache.entries[source] + entry := templateCache.entries[source] templateCache.RUnlock() - if t != nil { - return t.Clone(), nil + if entry != nil { + return entry.template.Clone(), entry, nil } t, e := raymond.Parse(source) if e != nil { - return nil, e + return nil, nil, e } + entry = &templateCacheEntry{template: t, source: source} templateCache.Lock() - if len(templateCache.entries) < 1024 && len(source) < 65536 { - templateCache.entries[source] = t + if existing := templateCache.entries[source]; existing != nil { + entry = existing + } else if len(templateCache.entries) < templateCacheEntries && templateCache.bytes+len(source) <= templateCacheBytes { + templateCache.entries[source] = entry + templateCache.bytes += len(source) } templateCache.Unlock() - return t.Clone(), nil + return t.Clone(), entry, nil } type templateValues []string @@ -125,14 +169,15 @@ func renderTemplateContext(source string, request Request, parameters map[string ctx[k] = v } } - t, err := cachedTemplate(source) + t, entry, err := cachedTemplate(source) if err != nil { return "", err } // Helper names are literal in Handlebars expressions. A substring check is // a conservative superset (including text literals), so it cannot omit a used helper. + mentions, recordMentions := entry.mentions() add := func(name string, f func(*raymond.Options) any) { - if strings.Contains(source, name) { + if mentions(name) { t.RegisterHelper(name, f) } } @@ -563,6 +608,7 @@ func renderTemplateContext(source string, request Request, parameters map[string add("now", templateDate) add("date", templateDate) add("parseDate", templateParseDate) + recordMentions() err = t.ValidateHelpers() if err == nil { result, err = t.Exec(ctx) diff --git a/pkg/breakmock/template_plan.go b/pkg/breakmock/template_plan.go index 9f3c533..b60d6d1 100644 --- a/pkg/breakmock/template_plan.go +++ b/pkg/breakmock/template_plan.go @@ -27,6 +27,7 @@ type templatePlan struct { var templatePlans = struct { sync.RWMutex entries map[string]*templatePlan + bytes int }{entries: map[string]*templatePlan{}} func lookupTemplatePlan(source string) *templatePlan { @@ -38,14 +39,15 @@ func lookupTemplatePlan(source string) *templatePlan { } plan = compileTemplatePlan(source) templatePlans.Lock() - if len(templatePlans.entries) < 1024 && len(source) < 65536 { + if _, exists := templatePlans.entries[source]; !exists && len(templatePlans.entries) < templateCacheEntries && templatePlans.bytes+len(source) <= templateCacheBytes { templatePlans.entries[source] = plan + templatePlans.bytes += len(source) } templatePlans.Unlock() return plan } func compileTemplatePlan(source string) *templatePlan { - if len(source) > 65536 || strings.Contains(source, "{{~") || strings.Contains(source, "~}}") { + if strings.Contains(source, "{{~") || strings.Contains(source, "~}}") { return nil } program, e := parser.Parse(source) diff --git a/scripts/diagnostics_differential.py b/scripts/diagnostics_differential.py index 5b54982..12ac793 100644 --- a/scripts/diagnostics_differential.py +++ b/scripts/diagnostics_differential.py @@ -1,6 +1,6 @@ #!/usr/bin/env python3 """Exact response bytes for unmatched requests and deterministic near-miss APIs.""" -import argparse,json,urllib.request,urllib.error,difflib,pathlib +import argparse,json,urllib.request,urllib.error,difflib,pathlib,re p=argparse.ArgumentParser();p.add_argument('--reference',default='http://127.0.0.1:18307');p.add_argument('--candidate',default='http://127.0.0.1:18308');p.add_argument('--output',default='testdata/reports/diagnostics.json');a=p.parse_args() def call(base,path,body=None,method=None,headers=None): data=json.dumps(body).encode() if isinstance(body,(dict,list)) else body.encode() if isinstance(body,str) else body @@ -12,7 +12,16 @@ def call(base,path,body=None,method=None,headers=None): from oracle import identify identify(a.reference,'java');identify(a.candidate,'go') results=[] -def case(name,patterns,path='/actual',method='GET',body=None,headers=None,extra=None,api=None): +JAVA_IDENTITY=re.compile(rb'\[B@[0-9a-f]{1,8}( *)') +def mask_identity(response): + # WireMock prints a binary mismatch's actual body as Java's default byte[] + # toString: "[B@" and a per-object JVM identity hash, never derived from the + # request. Replace only that token, keeping its column width, so alignment and + # every other byte are still compared. Each side must contain the Java shape. + status,body=response + masked,count=JAVA_IDENTITY.subn(lambda m:b'[B@#'.ljust(len(m.group(0))),body) + return (status,masked),count +def case(name,patterns,path='/actual',method='GET',body=None,headers=None,extra=None,api=None,java_identity=False): responses=[] for base in [a.reference,a.candidate]: call(base,'/__admin/reset',{},'POST') @@ -21,7 +30,13 @@ def case(name,patterns,path='/actual',method='GET',body=None,headers=None,extra= status,data=call(base,'/__admin/mappings',mapping,'POST') assert status==201,(name,base,status,data) responses.append(call(base,api or path,body,method,headers)) - ok=responses[0]==responses[1];result={'name':name,'pass':ok} + result={'name':name} + if java_identity: + masked=[mask_identity(r) for r in responses] + ok=all(count==1 for _,count in masked) and masked[0][0]==masked[1][0] + result['comparison']='exact bytes; JVM byte[] identity token masked width-for-width; both sides must contain one' + else:ok=responses[0]==responses[1] + result['pass']=ok if not ok: repeated=call(a.reference,api or path,body,method,headers) result['reference_repeat']={'status':repeated[0],'body':repeated[1].decode(errors='replace')} @@ -51,7 +66,7 @@ def case(name,patterns,path='/actual',method='GET',body=None,headers=None,extra= case('form mismatch',[{'formParameters':{'key':{'equalTo':'expected'}}}],method='POST',body='key=actual',headers={'Content-Type':'application/x-www-form-urlencoded'}) case('text body mismatch',[{'bodyPatterns':[{'equalTo':'expected'}]}],method='POST',body='actual') case('text body contains',[{'bodyPatterns':[{'contains':'expected'}]}],method='POST',body='actual') -case('binary body mismatch',[{'bodyPatterns':[{'binaryEqualTo':'YWJj'}]}],method='POST',body='actual') +case('binary body mismatch',[{'bodyPatterns':[{'binaryEqualTo':'YWJj'}]}],method='POST',body='actual',java_identity=True) case('scenario mismatch',[{'url':'/actual'}],extra={'scenarioName':'flow','requiredScenarioState':'Ready'}) case('path parameter mismatch',[{'urlPathTemplate':'/actual/{id}','pathParameters':{'id':{'equalTo':'123'}}}],path='/actual/456') case('closest URL distance',[{'url':'/nowhere'},{'url':'/actuaX'},{'url':'/somewhere'}]) diff --git a/scripts/dynamic_template_differential.py b/scripts/dynamic_template_differential.py new file mode 100644 index 0000000..12eb8cf --- /dev/null +++ b/scripts/dynamic_template_differential.py @@ -0,0 +1,274 @@ +#!/usr/bin/env python3 +# Copyright 2026 Breaking-IT. Apache-2.0. +"""Check that responses stay dynamic across requests, edits and caches. + +Single-request suites cannot detect a cache that serves stale or shared results. +This suite repeats requests against two dedicated servers, for small templates +and for templates above 64 KiB (the size at which template caching changed): + +* varying request values through plan-path and full-evaluator templates; +* random and time helpers, which must differ per request (property checks, as + the values cannot match Java byte for byte); +* mapping edits, body file edits and jsonBody edits, with and without gzip; +* raw non-ASCII header bytes in matching, templates and the journal; +* journal entries under concurrency, which must hold the body served to that request. + +Known divergence: WireMock serves a stale cached template after a templated +body file is edited; BreakMock must serve the edited file (checked, not compared). + +Responses are compared as exact status and body bytes unless noted. +Both servers are reset. Never use production servers. +""" +import argparse, base64, concurrent.futures, datetime, gzip, json, pathlib, re, socket, time, urllib.error, urllib.parse, urllib.request + +p = argparse.ArgumentParser() +p.add_argument('--reference', default='http://127.0.0.1:18087') +p.add_argument('--candidate', default='http://127.0.0.1:18088') +p.add_argument('--report', '--output', dest='report') +p.add_argument('--discover', action='store_true', help='Include known unsupported cases (template syntax errors)') +a = p.parse_args() +SERVERS = {'reference': a.reference, 'candidate': a.candidate} +MAPPING_ID = '0c7d9a52-1f3e-4b7a-9d2c-5e8f00000001' +records, failed = [], [] + + +def call(base, path, data=None, method=None, headers=None): + headers = dict(headers or {}) + if isinstance(data, (dict, list)): + data = json.dumps(data).encode(); headers.setdefault('Content-Type', 'application/json') + elif isinstance(data, str): + data = data.encode() + request = urllib.request.Request(base + path, data=data, method=method, headers=headers) + try: + response = urllib.request.urlopen(request, timeout=30) + except urllib.error.HTTPError as error: + response = error + with response: + return response.status, {k.lower(): v for k, v in response.headers.items()}, response.read() + + +def check(name, ok, detail=''): + records.append({'name': name, 'passed': bool(ok), 'detail': detail[:600]}) + print(('PASS ' if ok else 'FAIL ') + name + ('' if ok else ': ' + detail[:600])) + if not ok: + failed.append(name) + + +def body_of(result): + """Response body after transport decoding, for gzip comparisons.""" + status, headers, body = result + if headers.get('content-encoding') == 'gzip': + body = gzip.decompress(body) + return status, body + + +def short(result): + status, _, body = result + return f'{status} {body[:160]!r}...{body[-60:]!r} ({len(body)} bytes)' + + +def padding(size): + """Static text with newlines so templates are large and multi-line.""" + line = '{"pad":"' + 'p' * 90 + '"},\n' + return '[' + line * (size // len(line)) + '{"end":true}]' + + +SIZES = {'small': '', 'large': padding(80 * 1024)} + + +def put_mapping(base, response, request=None): + mapping = {'id': MAPPING_ID, 'request': request or {'urlPathPattern': '/dyn/.*'}, 'response': {'status': 200, **response}} + status, _, body = call(base, '/__admin/mappings/' + MAPPING_ID, mapping, method='PUT') + if status == 404: + status, _, body = call(base, '/__admin/mappings', mapping, method='POST') + if status not in (200, 201): + raise RuntimeError(f'{base}: mapping rejected {status} {body[:200]!r}') + + +def reset(): + for base in SERVERS.values(): + call(base, '/__admin/reset', method='POST') + + +def normalized(server, result): + """Replace the server's own address, which appears in Jetty error pages.""" + host = urllib.parse.urlsplit(SERVERS[server]).netloc.encode() + return result[0], result[2].replace(host, b'') + + +def compare(name, path, data=None, method=None, headers=None, decode=False): + results = {k: call(base, path, data, method, headers) for k, base in SERVERS.items()} + left, right = results['reference'], results['candidate'] + same = body_of(left) == body_of(right) if decode else normalized('reference', left) == normalized('candidate', right) + check(name, same, f"reference {short(left)} | candidate {short(right)}") + return results + + +# 1. Varying request values: every request must render its own values. +VALUES = ['alpha', 'beta', '', 'x', '&"quoted"\'', 'é漢字🙂', 'a b+c%2Fd', '12345', '-1.50', 'null', 'true', '{{not.a.template}}', + 'line\nbreak', 'z' * 300, 'tab\there', 'back\\slash', '$.path', 'üñí', 'X', 'beta'] +TEMPLATES = { + 'plan': '{"q":"{{request.query.q}}","h":"{{request.headers.X-V}}","seg":"{{request.path.[1]}}","method":"{{request.method}}","url":"{{request.url}}"}', + 'full evaluator': "{{jsonPath request.body '$.name'}}|{{#each (jsonPath request.body '$.items')}}{{this}},{{/each}}|{{upper request.query.q}}|" + "{{#if (eq request.query.q 'X')}}is-X{{else}}not-X{{/if}}|{{#assign 'v'}}{{request.query.q}}{{/assign}}[{{v}}]|{{size request.query.q}}", + 'escaping': '{{request.query.q}}|{{{request.query.q}}}|{{request.headers.X-V}}', +} +if a.discover: + # Known gap: Handlebars.java syntax error handling (see docs/COMPATIBILITY.md). + TEMPLATES['parse error'] = "{{jsonPath request.body '$.name'}}|{{#each (parseJson request.body).items}}{{this}}{{/each}}" +for size, pad in SIZES.items(): + for kind, template in TEMPLATES.items(): + reset() + for base in SERVERS.values(): + put_mapping(base, {'body': template + pad, 'transformers': ['response-template']}) + for i, value in enumerate(VALUES): + body = json.dumps({'name': value, 'items': [i, value]}) + header_value = value.encode('latin-1', 'replace').decode('latin-1').replace('\n', ' ') + compare(f'{size} {kind} value {i}', f'/dyn/seg{i}?q=' + urllib.parse.quote(value), body, 'POST', + {'Content-Type': 'application/json', 'X-V': header_value}) + +# 2. Random and time helpers: must change per request on both servers. +UUID = re.compile(r'^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$') +RANDOM = "{{randomValue type='UUID'}}|{{randomValue length=16 type='ALPHANUMERIC'}}|{{randomInt lower=0 upper=1000000000}}|{{now format='epoch'}}|{{pickRandom 'a' 'b' 'c' 'd' 'e' 'f' 'g' 'h'}}|" +for size, pad in SIZES.items(): + reset() + for base in SERVERS.values(): + put_mapping(base, {'body': RANDOM + pad, 'headers': {'X-Id': "{{randomValue type='UUID'}}"}, 'transformers': ['response-template']}) + for server, base in SERVERS.items(): + rows, header_ids = [], [] + for _ in range(30): + status, headers, body = call(base, '/dyn/random') + text = body.decode() + rows.append(text.split('|', 5)); header_ids.append(headers.get('x-id', '')) + now_ms = time.time() * 1000 + uuids, strings, ints, epochs, picks, rests = zip(*rows) + check(f'{size} random {server} UUID format', all(UUID.match(u) for u in uuids + tuple(header_ids)), str(uuids[:3])) + check(f'{size} random {server} UUIDs unique per request', len(set(uuids)) == 30 and len(set(header_ids)) == 30, f'{len(set(uuids))} body, {len(set(header_ids))} header') + check(f'{size} random {server} strings vary', len(set(strings)) == 30 and all(re.fullmatch('[A-Za-z0-9]{16}', s) for s in strings), str(strings[:3])) + check(f'{size} random {server} integers vary', len(set(ints)) >= 28, str(ints[:5])) + check(f'{size} random {server} now is current', all(abs(int(e) - now_ms) < 10_000 for e in epochs), str(epochs[:2])) + check(f'{size} random {server} pickRandom varies', len(set(picks)) >= 3 and set(picks) <= set('abcdefgh'), str(set(picks))) + check(f'{size} random {server} static text intact', set(rests) == {pad}, 'static part differs') + +# 3. Mapping edits: the newest definition must be served immediately. +EDITS = [ + ('template A', {'body': 'A={{request.query.a}}', 'transformers': ['response-template']}), + ('template B (same length)', {'body': 'B={{request.query.b}}', 'transformers': ['response-template']}), + ('template A again', {'body': 'A={{request.query.a}}', 'transformers': ['response-template']}), + ('helper added', {'body': "U={{upper request.query.a}}", 'transformers': ['response-template']}), + ('static text', {'body': 'S={{request.query.a}}'}), + ('templating disabled for same text', {'body': 'A={{request.query.a}}'}), + ('jsonBody', {'jsonBody': {'v': 1, 'pad': 'P'}}), + ('jsonBody edited', {'jsonBody': {'v': 2, 'pad': 'P'}}), + ('jsonBody template', {'jsonBody': {'v': '{{request.query.a}}', 'pad': 'P'}, 'transformers': ['response-template']}), +] +for size, pad in SIZES.items(): + reset() + for label, response in EDITS: + response = json.loads(json.dumps(response)) + if 'body' in response: + response['body'] += pad + else: + response['jsonBody']['pad'] += pad + for base in SERVERS.values(): + put_mapping(base, response) + for encoding in ('identity', 'gzip'): + compare(f'{size} mapping edit: {label} [{encoding}]', '/dyn/edit?a=first&b=second', headers={'Accept-Encoding': encoding}) + +# 4. Body file edits through the admin API, templated and static, with gzip. +FILES = [ + ('template v1', 'T1={{request.query.a}}', True), + ('template v2 (same length)', 'T2={{request.query.a}}', True), + ('template v1 again', 'T1={{request.query.a}}', True), + ('static v1', 'S1={{request.query.a}}', False), + ('static v2 (same length)', 'S2={{request.query.a}}', False), +] +for size, pad in SIZES.items(): + reset() + for label, content, templated in FILES: + for base in SERVERS.values(): + status, _, body = call(base, '/__admin/files/dynamic-body.json', content + pad, method='PUT') + if status not in (200, 201, 204): + raise RuntimeError(f'{base}: file write rejected {status} {body[:200]!r}') + put_mapping(base, {'bodyFileName': 'dynamic-body.json', **({'transformers': ['response-template']} if templated else {})}) + for encoding in ('identity', 'gzip'): + name = f'{size} file edit: {label} [{encoding}]' + if label.startswith('template v2'): + # Known divergence: WireMock keeps serving its cached compiled + # template after a templated body file is edited. BreakMock serves + # the new file, which is required here; Java's staleness is recorded. + results = {k: call(base, '/dyn/file?a=value', headers={'Accept-Encoding': encoding}) for k, base in SERVERS.items()} + fresh = ('T2=value' + pad).encode() + check(name + ' (candidate serves edited file)', body_of(results['candidate'])[1] == fresh, short(results['candidate'])) + records.append({'name': name + ' (reference)', 'passed': True, 'known_divergence': 'reference serves stale template: ' + body_of(results['reference'])[1][:12].decode(errors='replace')}) + continue + compare(name, '/dyn/file?a=value', headers={'Accept-Encoding': encoding}) + for base in SERVERS.values(): + call(base, '/__admin/files/dynamic-body.json', method='DELETE') + compare(f'{size} file edit: deleted file', '/dyn/file?a=value') + +# 5. Raw header bytes: Jetty decodes each header byte as ISO-8859-1, for +# matching, templates and the journal alike. +def raw_get(base, path, header): + url = urllib.parse.urlsplit(base) + with socket.create_connection((url.hostname, url.port), timeout=30) as connection: + connection.sendall(b'GET ' + path.encode() + b' HTTP/1.1\r\nHost: x\r\nX-V: ' + header + b'\r\nConnection: close\r\n\r\n') + data = b'' + while chunk := connection.recv(65536): + data += chunk + head, _, body = data.partition(b'\r\n\r\n') + if b'transfer-encoding: chunked' in head.lower(): + decoded = b'' + while True: + size, _, body = body.partition(b'\r\n') + size = int(size.split(b';')[0], 16) + if size == 0: + break + decoded, body = decoded + body[:size], body[size + 2:] + body = decoded + return head.split(b' ', 2)[1], body + + +HEADER_BYTES = [b'plain', b'\xe9', b'\xc3\xa9', b'\xf0\x9f\x99\x82', b'a\xe9b\xc3\xa9', b'\xff\xfe', b'tab\there'] +for size, pad in SIZES.items(): + reset() + for base in SERVERS.values(): + put_mapping(base, {'body': '[{{request.headers.X-V}}|{{{request.headers.X-V}}}]' + pad, 'transformers': ['response-template']}, {'urlPath': '/dyn/header'}) + call(base, '/__admin/mappings', {'priority': 1, 'request': {'urlPath': '/dyn/header', 'headers': {'X-V': {'equalTo': 'é'}}}, 'response': {'status': 200, 'body': 'matched é'}}, method='POST') + for value in HEADER_BYTES: + results = {k: raw_get(base, '/dyn/header', value) for k, base in SERVERS.items()} + check(f'{size} header bytes {value!r}', results['reference'] == results['candidate'], f"reference {results['reference'][1][:80]!r} | candidate {results['candidate'][1][:80]!r}") + logged = {} + for k, base in SERVERS.items(): + events = json.loads(call(base, '/__admin/requests')[2])['requests'] + logged[k] = [e['request']['headers'].get('X-V') for e in events] + check(f'{size} header bytes journal', logged['reference'] == logged['candidate'], f"reference {logged['reference']} | candidate {logged['candidate']}") + +# 6. Journal entries hold the body served to each request, under concurrency. +for size, pad in SIZES.items(): + reset() + for base in SERVERS.values(): + put_mapping(base, {'body': '{"id":"{{request.query.id}}"}' + pad, 'transformers': ['response-template']}) + for server, base in SERVERS.items(): + def fetch(i): + result = call(base, f'/dyn/journal?id={i}', headers={'Accept-Encoding': 'gzip' if i % 3 == 0 else 'identity'}) + return f'/dyn/journal?id={i}', result + with concurrent.futures.ThreadPoolExecutor(16) as pool: + served = dict(pool.map(fetch, range(120))) + _, _, raw = call(base, '/__admin/requests?limit=500') + events = json.loads(raw)['requests'] + logged = {e['request']['url']: base64.b64decode(e['response']['bodyAsBase64']) for e in events} + missing = [u for u in served if u not in logged] + wrong = [u for u, result in served.items() if u in logged and logged[u] not in (result[2], gzip.decompress(result[2]) if result[1].get('content-encoding') == 'gzip' else result[2])] + rendered = [u for u, result in served.items() if body_of(result)[1] != ('{"id":"%s"}' % u.rsplit('=', 1)[1] + pad).encode()] + check(f'{size} journal {server} logs every request', not missing, f'{len(missing)} missing') + check(f'{size} journal {server} logged bodies match served bodies', not wrong, f'{len(wrong)} differ, e.g. {wrong[:3]}') + check(f'{size} journal {server} concurrent responses rendered per request', not rendered, f'{len(rendered)} wrong, e.g. {rendered[:3]}') + +summary = {'reference_version': '4.0.0-beta.40', 'timestamp_utc': datetime.datetime.now(datetime.timezone.utc).isoformat(), + 'checks': len(records), 'passed': len(records) - len(failed), 'failed': failed} +print(json.dumps(summary)) +if a.report: + pathlib.Path(a.report).parent.mkdir(parents=True, exist_ok=True) + pathlib.Path(a.report).write_text(json.dumps({**summary, 'results': records}, indent=2) + '\n') +raise SystemExit(bool(failed)) diff --git a/scripts/json_benchmark.py b/scripts/json_benchmark.py new file mode 100644 index 0000000..3354d0a --- /dev/null +++ b/scripts/json_benchmark.py @@ -0,0 +1,207 @@ +#!/usr/bin/env python3 +"""Large JSON response benchmark comparing BreakMock builds (or WireMock) over real HTTP. + +Each workload serves one large JSON document (inline jsonBody, inline body, a +body file, response templates, and gzip). Every response is checked against the +bytes the first measured server produced, so all builds must serve identical +bodies. With journals enabled, the newest logged event is compared too. +Results are same-host observations; the load generator shares the CPU. +""" +import argparse, hashlib, json, os, pathlib, platform, subprocess, tempfile, threading, time, urllib.request + +ROOT = pathlib.Path(__file__).resolve().parent.parent + + +def document(size, template=''): + """Deterministic order listing of roughly size bytes (mirrors the Go benchmark).""" + customer = {'plan': '{{request.query.customer}}', 'helper': "{{jsonPath request.body '$.customer'}}"}.get(template, 'C-1001') + request_id = '{{request.headers.X-Request-Id}}' if template else 'r-1' + parts, length, i = [], 0, 0 + while length < size: + item = ('{"id":%d,"status":"SHIPPED","total":%d.%02d,"note":"Fragile \\u00e9 with care","items":[{"sku":"SKU-%05d","qty":%d,"price":19.95,"tags":["a","b"]},{"sku":"SKU-%05d","qty":1,"price":5.5,"tags":[]}],"address":{"street":"Main %d","city":"Amsterdam","zip":"1011AB"}}' + % (i, i * 7 % 1000, i % 100, i, i % 5 + 1, i + 1, i)) + parts.append(item); length += len(item) + 1; i += 1 + return '{"customer":"%s","currency":"EUR","orders":[%s],"requestId":"%s"}' % (customer, ','.join(parts), request_id) + + +def workloads(size): + static, plan, helper = document(size), document(size, 'plan'), document(size, 'helper') + json_headers = {'Content-Type': 'application/json'} + get = {'method': 'GET', 'url': '/orders?customer=C-1001', 'headers': ['X-Request-Id: r-1']} + post = {'method': 'POST', 'url': '/orders', 'headers': ['X-Request-Id: r-1', 'Content-Type: application/json'], 'body': b'{"customer":"C-1001"}'} + match_get = {'method': 'GET', 'urlPath': '/orders'} + template = ['response-template'] + return { + 'jsonBody': (get, match_get, {'status': 200, 'headers': json_headers, 'jsonBody': json.loads(static)}, None), + 'body': (get, match_get, {'status': 200, 'headers': json_headers, 'body': static}, None), + 'bodyFileName': (get, match_get, {'status': 200, 'headers': json_headers, 'bodyFileName': 'orders.json'}, ('orders.json', static)), + 'templateBody': (get, match_get, {'status': 200, 'headers': json_headers, 'body': plan, 'transformers': template}, None), + 'templateFile': (get, match_get, {'status': 200, 'headers': json_headers, 'bodyFileName': 'orders-template.json', 'transformers': template}, ('orders-template.json', plan)), + 'templateHelper': (post, {'method': 'POST', 'urlPath': '/orders'}, {'status': 200, 'headers': json_headers, 'body': helper, 'transformers': template}, None), + 'jsonBodyGzip': (dict(get, headers=get['headers'] + ['Accept-Encoding: gzip']), match_get, {'status': 200, 'headers': json_headers, 'jsonBody': json.loads(static)}, None), + } + + +def admin(port, path, data=None, method=None): + body = None if data is None else json.dumps(data).encode() + request = urllib.request.Request(f'http://127.0.0.1:{port}{path}', data=body, method=method, headers={'Content-Type': 'application/json'}) + return urllib.request.urlopen(request, timeout=30).read() + + +def fetch(port, spec): + request = urllib.request.Request(f'http://127.0.0.1:{port}{spec["url"]}', data=spec.get('body'), method=spec['method']) + for header in spec['headers']: + name, value = header.split(':', 1); request.add_header(name.strip(), value.strip()) + with urllib.request.urlopen(request, timeout=30) as response: + return response.read() + + +def cpu_seconds(pid): + value = subprocess.check_output(['ps', '-o', 'time=', '-p', str(pid)], text=True).strip() + days = 0 + if '-' in value: + day, value = value.split('-', 1); days = int(day) + return days * 86400 + sum(float(v) * 60 ** i for i, v in enumerate(reversed(value.split(':')))) + + +def rss_mib(pid): + try: + return int(subprocess.check_output(['ps', '-o', 'rss=', '-p', str(pid)], text=True).strip()) / 1024 + except Exception: + return 0 + + +def normalized_event(raw): + event = json.loads(raw)['requests'][0] + for key in ('id', 'timing'): + event.pop(key, None) + for key in ('loggedDate', 'loggedDateString', 'clientIp'): + event['request'].pop(key, None) + for headers in (event['request'].get('headers', {}),): + for key in ('Host', 'Connection'): + headers.pop(key, None) + return event + + +def main(): + p = argparse.ArgumentParser(description=__doc__) + p.add_argument('--binary', action='append', required=True, help='name=path of a BreakMock executable or WireMock .jar; repeat to compare') + p.add_argument('--size', type=int, default=100 * 1024, help='approximate JSON document size in bytes') + p.add_argument('--rounds', type=int, default=3) + p.add_argument('--duration', default='5s') + p.add_argument('--warmup', default='2s') + p.add_argument('--concurrency', type=int, default=32) + p.add_argument('--journal', choices=['disabled', 'capped', 'both'], default='both') + p.add_argument('--workloads', default='', help='comma-separated subset') + p.add_argument('--journal-check', choices=['strict', 'report'], default='strict', + help='strict fails on a differing logged event; report records the difference and continues') + p.add_argument('--source-revision', default='', help='Commit the measured BreakMock builds came from, recorded in the report') + p.add_argument('--output', required=True) + a = p.parse_args() + binaries = dict(item.split('=', 1) for item in a.binary) + binaries = {name: pathlib.Path(path).resolve() for name, path in binaries.items()} + driver = ROOT / 'bin/bmbench' + subprocess.run(['go', 'build', '-o', str(driver), './cmd/bmbench'], cwd=ROOT, check=True) + selected = workloads(a.size) + if a.workloads: + selected = {k: v for k, v in selected.items() if k in a.workloads.split(',')} + journals = ['disabled', 'capped'] if a.journal == 'both' else [a.journal] + work = pathlib.Path(tempfile.mkdtemp(prefix='bm-json-')) + root = work / 'root'; (root / '__files').mkdir(parents=True) + expected, logged, results, journal_differences = {}, {}, [], set() + for _, _, _, file in selected.values(): + if file: + (root / '__files' / file[0]).write_text(file[1]) + names = list(binaries) + for journal in journals: + for round_index in range(a.rounds): + shift = round_index % len(names) + for name in names[shift:] + names[:shift]: + port = 18200 # one port, so logged URLs are comparable across servers + command = [str(binaries[name]), '--port', str(port), '--bind-address', '127.0.0.1', '--root-dir', str(root)] + if binaries[name].suffix == '.jar': + command = ['java', '-jar'] + command + ['--disable-banner'] + command += ['--no-request-journal'] if journal == 'disabled' else ['--max-request-journal-entries', '1000'] + proc = subprocess.Popen(command, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) + try: + for _ in range(600): + try: + admin(port, '/__admin/mappings'); break + except Exception: + time.sleep(.05) + else: + raise RuntimeError(f'{name} did not start') + for workload, (spec, match, response, _) in selected.items(): + admin(port, '/__admin/reset', {}) + admin(port, '/__admin/mappings', {'id': '7d5a1f5e-0000-4000-8000-000000000001', 'request': match, 'response': response}) + body = fetch(port, spec) + key = (workload,) + if key not in expected: + path = work / f'{workload}.expected'; path.write_bytes(body); expected[key] = path + elif body != expected[key].read_bytes(): + raise RuntimeError(f'{name} {workload}: response differs from the first server') + if journal == 'capped': + event = normalized_event(admin(port, '/__admin/requests?limit=1')) + if workload not in logged: + logged[workload] = event + elif event != logged[workload]: + if a.journal_check == 'strict': + raise RuntimeError(f'{name} {workload}: journal event differs from the first server') + differing = sorted(k for k in set(event) | set(logged[workload]) if event.get(k) != logged[workload].get(k)) + journal_differences.add((name, workload, ','.join(differing))) + driver_command = [str(driver), '--url', f'http://127.0.0.1:{port}{spec["url"]}', '--method', spec['method'], + '--concurrency', str(a.concurrency), '--expected-body-file', str(expected[key])] + for header in spec['headers']: + driver_command += ['--header', header] + if spec.get('body'): + request_file = work / f'{workload}.request'; request_file.write_bytes(spec['body']) + driver_command += ['--body-file', str(request_file)] + subprocess.run(driver_command + ['--duration', a.warmup], check=True, stdout=subprocess.DEVNULL) + samples, stop = [], threading.Event() + sampler = threading.Thread(target=lambda: [samples.append(rss_mib(proc.pid)) for _ in iter(lambda: stop.wait(.1), True)]) + sampler.start() + cpu_start, wall_start = cpu_seconds(proc.pid), time.monotonic() + try: + run = json.loads(subprocess.check_output(driver_command + ['--duration', a.duration], text=True)) + cpu = cpu_seconds(proc.pid) - cpu_start; wall = time.monotonic() - wall_start + finally: + stop.set(); sampler.join() + run.update(server=name, journal=journal, workload=workload, round=round_index + 1, response_body_bytes=len(body), + server_cpu_seconds=cpu, server_cpu_us_per_request=cpu * 1e6 / max(run['requests'], 1), + server_cpu_percent_one_core=100 * cpu / wall, peak_sampled_rss_mib=max(samples or [rss_mib(proc.pid)]), + mib_per_second=run['response_bytes'] / run['seconds'] / (1 << 20)) + results.append(run) + print(f"{journal:8} r{round_index + 1} {name:10} {workload:15} {run['rps']:10.0f} rps {run['mib_per_second']:8.1f} MiB/s " + f"cpu {run['server_cpu_us_per_request']:8.1f} us/req p99 {run['p99_ms']:.2f} ms", flush=True) + finally: + proc.terminate() + try: + proc.wait(timeout=10) + except subprocess.TimeoutExpired: + proc.kill(); proc.wait() + summary = {} + for r in results: + s = summary.setdefault(f"{r['journal']}/{r['workload']}", {}).setdefault(r['server'], {'rps': [], 'cpu_us': [], 'p99_ms': [], 'rss': []}) + s['rps'].append(r['rps']); s['cpu_us'].append(r['server_cpu_us_per_request']); s['p99_ms'].append(r['p99_ms']); s['rss'].append(r['peak_sampled_rss_mib']) + report = { + 'platform': platform.platform(), 'machine': platform.machine(), 'logical_cpus': os.cpu_count(), + 'go_version': subprocess.check_output(['go', 'version'], text=True).strip(), + 'java_version': subprocess.run(['java', '-version'], capture_output=True, text=True).stderr.strip() if any(v.suffix == '.jar' for v in binaries.values()) else None, + 'binaries': {k: {'path': str(v), 'sha256': hashlib.sha256(v.read_bytes()).hexdigest()} for k, v in binaries.items()}, + 'driver_sha256': hashlib.sha256(driver.read_bytes()).hexdigest(), + 'source_revision': a.source_revision or subprocess.check_output(['git', 'rev-parse', 'HEAD'], cwd=ROOT, text=True).strip(), + 'source_dirty': bool(subprocess.check_output(['git', 'status', '--porcelain'], cwd=ROOT, text=True).strip()), + 'settings': {'size': a.size, 'rounds': a.rounds, 'duration': a.duration, 'warmup': a.warmup, 'concurrency': a.concurrency, + 'response_body_bytes': {k[0]: v.stat().st_size for k, v in expected.items()}}, + 'notes': ['Unlimited-rate closed loop with persistent connections; driver and servers share the host.', + 'Every response is compared byte-for-byte with the first server\'s response for that workload.', + 'With capped journals, the newest logged event (ids, timings and client details removed) must be identical across servers.', + 'Server CPU is the ps user+system delta over the measurement window divided by completed requests.'], + 'journal_differences': [{'server': n, 'workload': w, 'differing_event_fields': f} for n, w, f in sorted(journal_differences)], + 'summary': summary, 'results': results} + pathlib.Path(a.output).parent.mkdir(parents=True, exist_ok=True) + pathlib.Path(a.output).write_text(json.dumps(report, indent=2)) + + +if __name__ == '__main__': + main() diff --git a/scripts/template_differential.py b/scripts/template_differential.py index 79bb5b6..7cbc499 100644 --- a/scripts/template_differential.py +++ b/scripts/template_differential.py @@ -8,7 +8,8 @@ Both servers' mappings and request journals are reset. Never use production servers. """ import argparse,json,urllib.request,urllib.error,pathlib,datetime -p=argparse.ArgumentParser();p.add_argument('--reference',default='http://127.0.0.1:18087');p.add_argument('--candidate',default='http://127.0.0.1:18088');p.add_argument('--discover',action='store_true',help='Include known unsupported helper coverage');p.add_argument('--report','--output',dest='report');a=p.parse_args() +p=argparse.ArgumentParser();p.add_argument('--reference',default='http://127.0.0.1:18087');p.add_argument('--candidate',default='http://127.0.0.1:18088');p.add_argument('--discover',action='store_true',help='Include known unsupported helper coverage');p.add_argument('--report','--output',dest='report');p.add_argument('--pad',type=int,default=0,help='Append this many bytes of static text to each string template, to exercise large-template caching');p.add_argument('--repeat',type=int,default=1,help='Requests per case; every repetition must match');a=p.parse_args() +PAD=('\n'+'p'*99)*(a.pad//100) def call(base,path,data=None,method=None,headers=None): if isinstance(data,dict):data=json.dumps(data).encode();headers={'Content-Type':'application/json',**(headers or {})} if isinstance(data,str):data=data.encode() @@ -87,8 +88,10 @@ def add(name,template,body='',path='/template-test?q=one&q=two',headers=None,par results=[] for base in (a.reference,a.candidate): call(base,'/__admin/reset',method='POST') - s,b=call(base,'/__admin/mappings',{'request':{'urlPath':'/template-test'},'response':{'status':200,**({'jsonBody':t} if isinstance(t,dict) else {'body':t}),'transformers':['response-template'],'transformerParameters':parameters_by_name.get(name,{})}}) - results.append(call(base,path,body,headers=headers) if s==201 else ('mapping rejected',s,b)) + s,b=call(base,'/__admin/mappings',{'request':{'urlPath':'/template-test'},'response':{'status':200,**({'jsonBody':t} if isinstance(t,dict) else {'body':t+PAD}),'transformers':['response-template'],'transformerParameters':parameters_by_name.get(name,{})}}) + repeated=[call(base,path,body,headers=headers) if s==201 else ('mapping rejected',s,b) for _ in range(a.repeat)] + if any(r!=repeated[0] for r in repeated):repeated[0]=('repeated responses differ',)+repeated[0] + results.append(repeated[0]) diagnostic = name in ('jsonBody template quotes','jsonBody template newline') and results[0][0]==500 comparison='status_and_exact_body_bytes' ok=results[0]==results[1] diff --git a/scripts/verify.py b/scripts/verify.py index cea5bfa..0c88a49 100644 --- a/scripts/verify.py +++ b/scripts/verify.py @@ -9,7 +9,7 @@ binary=root/'bin/breakmock' output=pathlib.Path(a.output_dir or 'testdata/reports');output.mkdir(parents=True,exist_ok=True) reference='http://127.0.0.1:18111';candidate='http://127.0.0.1:18112';results=[] -suites=['fixtures_differential.py','differential.py','matcher_differential.py','template_differential.py','admin_differential.py','runtime_differential.py','gzip_differential.py','diagnostics_differential.py','matcher_distance_differential.py','webhook_differential.py','fault_differential.py','entity_differential.py','messaging_differential.py','streaming_differential.py','status_differential.py','streaming_journal_differential.py','message_wait_differential.py','journal_concurrency_differential.py'] +suites=['fixtures_differential.py','differential.py','matcher_differential.py','template_differential.py','admin_differential.py','runtime_differential.py','gzip_differential.py','diagnostics_differential.py','matcher_distance_differential.py','webhook_differential.py','fault_differential.py','entity_differential.py','messaging_differential.py','streaming_differential.py','status_differential.py','streaming_journal_differential.py','message_wait_differential.py','journal_concurrency_differential.py','dynamic_template_differential.py'] for suite,disabled_journal in [(suite,False) for suite in suites]+[('message_wait_differential.py',True)]: suite_name=suite+(':disabled-journal' if disabled_journal else '') if a.suite and suite not in a.suite and suite_name not in a.suite:continue @@ -34,7 +34,7 @@ except (OSError,ValueError):time.sleep(.1) else:raise RuntimeError(kind+' startup timeout') cmd=[sys.executable,str(root/'scripts'/suite),'--reference',reference,'--candidate',candidate] - reports={'differential.py':'compatibility','matcher_differential.py':'matcher','admin_differential.py':'admin','runtime_differential.py':'runtime','template_differential.py':'template','gzip_differential.py':'gzip','diagnostics_differential.py':'diagnostics','matcher_distance_differential.py':'matcher-distance','webhook_differential.py':'webhook','fault_differential.py':'faults','entity_differential.py':'entities','messaging_differential.py':'messaging','streaming_differential.py':'streaming','status_differential.py':'status','streaming_journal_differential.py':'streaming-journal','message_wait_differential.py':'message-wait','journal_concurrency_differential.py':'journal-concurrency'} + reports={'differential.py':'compatibility','matcher_differential.py':'matcher','admin_differential.py':'admin','runtime_differential.py':'runtime','template_differential.py':'template','gzip_differential.py':'gzip','diagnostics_differential.py':'diagnostics','matcher_distance_differential.py':'matcher-distance','webhook_differential.py':'webhook','fault_differential.py':'faults','entity_differential.py':'entities','messaging_differential.py':'messaging','streaming_differential.py':'streaming','status_differential.py':'status','streaming_journal_differential.py':'streaming-journal','message_wait_differential.py':'message-wait','journal_concurrency_differential.py':'journal-concurrency','dynamic_template_differential.py':'dynamic-template'} if suite in reports:cmd+=['--output',str(output/((reports[suite]+'-disabled' if disabled_journal else reports[suite])+'.json'))] if disabled_journal:cmd+=['--disabled-journal'] if suite=='journal_concurrency_differential.py':cmd+=['--capacity','64','--scenario-check'] diff --git a/testdata/reports/benchmark-large-json-10mib.json b/testdata/reports/benchmark-large-json-10mib.json new file mode 100644 index 0000000..65c5826 --- /dev/null +++ b/testdata/reports/benchmark-large-json-10mib.json @@ -0,0 +1,1377 @@ +{ + "platform": "macOS-27.0.1-arm64-arm-64bit-Mach-O", + "machine": "arm64", + "logical_cpus": 14, + "go_version": "go version go1.27.1 darwin/arm64", + "java_version": "openjdk version \"27\" 2026-09-15\nOpenJDK Runtime Environment Homebrew (build 27)\nOpenJDK 64-Bit Server VM Homebrew (build 27, mixed mode, sharing)", + "binaries": { + "java": { + "path": "wiremock.jar", + "sha256": "3a53dec6c814ff73da4abb0bc51624215ea2b913beec8d19aa6d54e4c62161d3" + }, + "go": { + "path": "breakmock-release", + "sha256": "27907252cfd00980e64b1b3af9820acf71556691057c846fc1e55720248c4405" + } + }, + "driver_sha256": "d1c95028a7901028d5f58236ab80683283a72a9f7d570f0b20cd9c12d99f0224", + "source_revision": "68cd31176154240eb238d4e1a743b414cf5fdfb9", + "source_dirty": false, + "settings": { + "size": 10485760, + "rounds": 3, + "duration": "5s", + "warmup": "2s", + "concurrency": 32, + "response_body_bytes": { + "jsonBody": 10330494, + "body": 10486094, + "bodyFileName": 10486094, + "templateBody": 10486094, + "templateFile": 10486094, + "templateHelper": 10486094, + "jsonBodyGzip": 593878 + } + }, + "notes": [ + "Unlimited-rate closed loop with persistent connections; driver and servers share the host.", + "Every response is compared byte-for-byte with the first server's response for that workload.", + "With capped journals, the newest logged event (ids, timings and client details removed) must be identical across servers.", + "Server CPU is the ps user+system delta over the measurement window divided by completed requests." + ], + "journal_differences": [], + "summary": { + "disabled/jsonBody": { + "java": { + "rps": [ + 49.08722724695123, + 58.10809534464501, + 57.49795760204689 + ], + "cpu_us": [ + 127148.43749999999, + 141881.18811881187, + 105573.24840764332 + ], + "p99_ms": [ + 2916.773, + 3015.586, + 2518.437 + ], + "rss": [ + 10634.734375, + 11573.828125, + 10911.984375 + ] + }, + "go": { + "rps": [ + 869.0067296480665, + 862.308318926104, + 854.9365256857304 + ], + "cpu_us": [ + 1971.1207884483154, + 2006.4575645756458, + 1963.6617749825298 + ], + "p99_ms": [ + 40.462, + 40.311, + 57.089 + ], + "rss": [ + 389.734375, + 421.875, + 435.671875 + ] + } + }, + "disabled/body": { + "java": { + "rps": [ + 247.31840862421987, + 285.87203239934695, + 247.23517791213905 + ], + "cpu_us": [ + 32188.739095955592, + 32947.658402203866, + 29865.39984164686 + ], + "p99_ms": [ + 672.815, + 824.978, + 860.297 + ], + "rss": [ + 11455.03125, + 11730.90625, + 11131.375 + ] + }, + "go": { + "rps": [ + 858.5353133399291, + 845.3639317403923, + 817.3210217293944 + ], + "cpu_us": [ + 2034.3307817211785, + 2090.9948137670904, + 2043.351193375548 + ], + "p99_ms": [ + 46.11, + 41.461, + 43.357 + ], + "rss": [ + 389.90625, + 422.125, + 435.953125 + ] + } + }, + "disabled/bodyFileName": { + "java": { + "rps": [ + 290.87696500116954, + 256.7390893261394, + 301.57381005975583 + ], + "cpu_us": [ + 24008.124576844963, + 26388.036809815952, + 22097.71986970684 + ], + "p99_ms": [ + 458.099, + 714.683, + 422.477 + ], + "rss": [ + 9865.90625, + 11322.859375, + 10073.71875 + ] + }, + "go": { + "rps": [ + 839.1847475582055, + 853.2383540485203, + 842.8567121162397 + ], + "cpu_us": [ + 2160.493827160494, + 1999.9999999999995, + 1915.7994323557234 + ], + "p99_ms": [ + 41.873, + 41.546, + 46.151 + ], + "rss": [ + 389.984375, + 422.1875, + 436.0 + ] + } + }, + "disabled/templateBody": { + "java": { + "rps": [ + 232.54600476974895, + 99.96016149611833, + 101.86878421939956 + ], + "cpu_us": [ + 41631.62321278385, + 52090.301003344495, + 50040.43126684639 + ], + "p99_ms": [ + 2084.232, + 3233.171, + 2393.254 + ], + "rss": [ + 12637.578125, + 12586.484375, + 12571.34375 + ] + }, + "go": { + "rps": [ + 836.9260845889737, + 828.9904985126599, + 816.8361957367649 + ], + "cpu_us": [ + 2611.283027850511, + 2584.053794428434, + 2688.276870582501 + ], + "p99_ms": [ + 42.264, + 42.004, + 42.518 + ], + "rss": [ + 874.25, + 831.734375, + 745.375 + ] + } + }, + "disabled/templateFile": { + "java": { + "rps": [ + 215.60341161355112, + 105.82541320662594, + 172.79763726808127 + ], + "cpu_us": [ + 45117.75362318838, + 61715.867158671565, + 45804.98866213153 + ], + "p99_ms": [ + 1365.347, + 1696.597, + 1279.839 + ], + "rss": [ + 12655.890625, + 12595.359375, + 12610.671875 + ] + }, + "go": { + "rps": [ + 822.0388270928122, + 826.0722584204157, + 835.0458842183197 + ], + "cpu_us": [ + 2931.91180033923, + 2926.711668273867, + 2987.601335240819 + ], + "p99_ms": [ + 42.297, + 42.194, + 44.461 + ], + "rss": [ + 874.421875, + 832.015625, + 825.8125 + ] + } + }, + "disabled/templateHelper": { + "java": { + "rps": [ + 221.9292503006704, + 126.17788816498287, + 193.83430021690629 + ], + "cpu_us": [ + 42768.9594356261, + 51625.38699690406, + 43211.53846153846 + ], + "p99_ms": [ + 1031.614, + 1650.813, + 2781.562 + ], + "rss": [ + 12612.359375, + 12632.921875, + 12665.4375 + ] + }, + "go": { + "rps": [ + 840.8156379135053, + 826.0948044786239, + 833.9808547501857 + ], + "cpu_us": [ + 2576.9777356702975, + 2558.4196579137533, + 2658.86287625418 + ], + "p99_ms": [ + 41.136, + 41.6, + 50.876 + ], + "rss": [ + 874.78125, + 852.40625, + 896.40625 + ] + } + }, + "disabled/jsonBodyGzip": { + "java": { + "rps": [ + 93.94802601219251, + 78.1611102039266, + 53.566072774775684 + ], + "cpu_us": [ + 121174.08906882594, + 123317.30769230773, + 128881.35593220334 + ], + "p99_ms": [ + 3761.11, + 3641.239, + 2139.137 + ], + "rss": [ + 12554.09375, + 12661.875, + 11868.46875 + ] + }, + "go": { + "rps": [ + 15623.101439722095, + 15798.369271558402, + 15603.669967182565 + ], + "cpu_us": [ + 577.8778727542611, + 587.848184567878, + 571.4358928365513 + ], + "p99_ms": [ + 7.199, + 7.022, + 7.444 + ], + "rss": [ + 876.96875, + 854.984375, + 898.25 + ] + } + } + }, + "results": [ + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 369.16, + "p95_ms": 2517.606, + "p99_ms": 2916.773, + "requests": 256, + "response_bytes": 2644606464, + "rps": 49.08722724695123, + "seconds": 5.215205958, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 10330494, + "server_cpu_seconds": 32.55, + "server_cpu_us_per_request": 127148.43749999999, + "server_cpu_percent_one_core": 620.319385671226, + "peak_sampled_rss_mib": 10634.734375, + "mib_per_second": 483.6037698280966 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 80.93, + "p95_ms": 395.888, + "p99_ms": 672.815, + "requests": 1261, + "response_bytes": 13222964534, + "rps": 247.31840862421987, + "seconds": 5.098690417, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "body", + "round": 1, + "response_body_bytes": 10486094, + "server_cpu_seconds": 40.59, + "server_cpu_us_per_request": 32188.739095955592, + "server_cpu_percent_one_core": 792.9870173880078, + "peak_sampled_rss_mib": 11455.03125, + "mib_per_second": 2473.2628638877677 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 76.705, + "p95_ms": 308.522, + "p99_ms": 458.099, + "requests": 1477, + "response_bytes": 15487960838, + "rps": 290.87696500116954, + "seconds": 5.07774825, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 10486094, + "server_cpu_seconds": 35.46000000000001, + "server_cpu_us_per_request": 24008.124576844963, + "server_cpu_percent_one_core": 695.4068029987192, + "peak_sampled_rss_mib": 9865.90625, + "mib_per_second": 2908.862302243208 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 81.379, + "p95_ms": 306.389, + "p99_ms": 2084.232, + "requests": 1189, + "response_bytes": 12467965766, + "rps": 232.54600476974895, + "seconds": 5.112966792, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 10486094, + "server_cpu_seconds": 49.5, + "server_cpu_us_per_request": 41631.62321278385, + "server_cpu_percent_one_core": 963.4222393002461, + "peak_sampled_rss_mib": 12637.578125, + "mib_per_second": 2325.5341199303016 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 87.64, + "p95_ms": 501.376, + "p99_ms": 1365.347, + "requests": 1104, + "response_bytes": 11576647776, + "rps": 215.60341161355112, + "seconds": 5.120512666, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 10486094, + "server_cpu_seconds": 49.809999999999974, + "server_cpu_us_per_request": 45117.75362318838, + "server_cpu_percent_one_core": 968.98271297915, + "peak_sampled_rss_mib": 12655.890625, + "mib_per_second": 2156.102791691197 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 86.798, + "p95_ms": 622.201, + "p99_ms": 1031.614, + "requests": 1134, + "response_bytes": 11891230596, + "rps": 221.9292503006704, + "seconds": 5.109736542, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "disabled", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 10486094, + "server_cpu_seconds": 48.5, + "server_cpu_us_per_request": 42768.9594356261, + "server_cpu_percent_one_core": 944.9373020675334, + "peak_sampled_rss_mib": 12612.359375, + "mib_per_second": 2219.3631935142116 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 205.988, + "p95_ms": 920.653, + "p99_ms": 3761.11, + "requests": 494, + "response_bytes": 293375732, + "rps": 93.94802601219251, + "seconds": 5.2582265, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 593878, + "server_cpu_seconds": 59.860000000000014, + "server_cpu_us_per_request": 121174.08906882594, + "server_cpu_percent_one_core": 1135.8416179203064, + "peak_sampled_rss_mib": 12554.09375, + "mib_per_second": 53.208986084050046 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 36.675, + "p95_ms": 39.379, + "p99_ms": 40.462, + "requests": 4363, + "response_bytes": 45071945322, + "rps": 869.0067296480665, + "seconds": 5.020674583, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 10330494, + "server_cpu_seconds": 8.6, + "server_cpu_us_per_request": 1971.1207884483154, + "server_cpu_percent_one_core": 170.75430041864095, + "peak_sampled_rss_mib": 389.734375, + "mib_per_second": 8561.390692318892 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 37.575, + "p95_ms": 40.042, + "p99_ms": 46.11, + "requests": 4311, + "response_bytes": 45205551234, + "rps": 858.5353133399291, + "seconds": 5.021342667, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "body", + "round": 1, + "response_body_bytes": 10486094, + "server_cpu_seconds": 8.77, + "server_cpu_us_per_request": 2034.3307817211785, + "server_cpu_percent_one_core": 174.04433532462474, + "peak_sampled_rss_mib": 389.90625, + "mib_per_second": 8585.626600267362 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 38.274, + "p95_ms": 40.298, + "p99_ms": 41.873, + "requests": 4212, + "response_bytes": 44167427928, + "rps": 839.1847475582055, + "seconds": 5.019157, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 10486094, + "server_cpu_seconds": 9.100000000000001, + "server_cpu_us_per_request": 2160.493827160494, + "server_cpu_percent_one_core": 180.70635629789334, + "peak_sampled_rss_mib": 389.984375, + "mib_per_second": 8392.114778768171 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 38.243, + "p95_ms": 40.983, + "p99_ms": 42.264, + "requests": 4201, + "response_bytes": 44052080894, + "rps": 836.9260845889737, + "seconds": 5.019559167, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 10486094, + "server_cpu_seconds": 10.969999999999999, + "server_cpu_us_per_request": 2611.283027850511, + "server_cpu_percent_one_core": 217.7605479917095, + "peak_sampled_rss_mib": 874.25, + "mib_per_second": 8369.527429630212 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 38.888, + "p95_ms": 41.263, + "p99_ms": 42.297, + "requests": 4127, + "response_bytes": 43276109938, + "rps": 822.0388270928122, + "seconds": 5.020444125, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 10486094, + "server_cpu_seconds": 12.100000000000001, + "server_cpu_us_per_request": 2931.91180033923, + "server_cpu_percent_one_core": 240.1366476745128, + "peak_sampled_rss_mib": 874.421875, + "mib_per_second": 8220.650112671829 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 38.133, + "p95_ms": 40.24, + "p99_ms": 41.136, + "requests": 4222, + "response_bytes": 44272288868, + "rps": 840.8156379135053, + "seconds": 5.021314792, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go", + "journal": "disabled", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 10486094, + "server_cpu_seconds": 10.879999999999995, + "server_cpu_us_per_request": 2576.9777356702975, + "server_cpu_percent_one_core": 215.95321991659864, + "peak_sampled_rss_mib": 874.78125, + "mib_per_second": 8408.424201804142 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.727, + "p95_ms": 4.199, + "p99_ms": 7.199, + "requests": 78148, + "response_bytes": 46410377944, + "rps": 15623.101439722095, + "seconds": 5.002079792, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 593878, + "server_cpu_seconds": 45.16, + "server_cpu_us_per_request": 577.8778727542611, + "server_cpu_percent_one_core": 899.9962757102301, + "peak_sampled_rss_mib": 876.96875, + "mib_per_second": 8848.396527117995 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 36.976, + "p95_ms": 39.448, + "p99_ms": 40.311, + "requests": 4336, + "response_bytes": 44793021984, + "rps": 862.308318926104, + "seconds": 5.028363875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 10330494, + "server_cpu_seconds": 8.7, + "server_cpu_us_per_request": 2006.4575645756458, + "server_cpu_percent_one_core": 172.41168890087437, + "peak_sampled_rss_mib": 421.875, + "mib_per_second": 8495.398440185741 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 38.037, + "p95_ms": 40.332, + "p99_ms": 41.461, + "requests": 4242, + "response_bytes": 44482010748, + "rps": 845.3639317403923, + "seconds": 5.017957167, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "body", + "round": 2, + "response_body_bytes": 10486094, + "server_cpu_seconds": 8.869999999999997, + "server_cpu_us_per_request": 2090.9948137670904, + "server_cpu_percent_one_core": 176.08653825207767, + "peak_sampled_rss_mib": 422.125, + "mib_per_second": 8453.908588828408 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 37.399, + "p95_ms": 40.09, + "p99_ms": 41.546, + "requests": 4290, + "response_bytes": 44985343260, + "rps": 853.2383540485203, + "seconds": 5.027903375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 10486094, + "server_cpu_seconds": 8.579999999999998, + "server_cpu_us_per_request": 1999.9999999999995, + "server_cpu_percent_one_core": 170.0753664547043, + "peak_sampled_rss_mib": 422.1875, + "mib_per_second": 8532.655320127547 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 38.563, + "p95_ms": 40.862, + "p99_ms": 42.004, + "requests": 4164, + "response_bytes": 43664095416, + "rps": 828.9904985126599, + "seconds": 5.02297675, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 10486094, + "server_cpu_seconds": 10.759999999999998, + "server_cpu_us_per_request": 2584.053794428434, + "server_cpu_percent_one_core": 213.47083640317658, + "peak_sampled_rss_mib": 831.734375, + "mib_per_second": 8290.16904116689 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 38.809, + "p95_ms": 40.806, + "p99_ms": 42.194, + "requests": 4148, + "response_bytes": 43496317912, + "rps": 826.0722584204157, + "seconds": 5.0213525, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 10486094, + "server_cpu_seconds": 12.14, + "server_cpu_us_per_request": 2926.711668273867, + "server_cpu_percent_one_core": 240.95875784351588, + "peak_sampled_rss_mib": 832.015625, + "mib_per_second": 8260.985710705538 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 38.687, + "p95_ms": 40.814, + "p99_ms": 41.6, + "requests": 4151, + "response_bytes": 43527776194, + "rps": 826.0948044786239, + "seconds": 5.024847, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go", + "journal": "disabled", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 10486094, + "server_cpu_seconds": 10.61999999999999, + "server_cpu_us_per_request": 2558.4196579137533, + "server_cpu_percent_one_core": 210.57377785278612, + "peak_sampled_rss_mib": 852.40625, + "mib_per_second": 8261.211178469153 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.71, + "p95_ms": 4.169, + "p99_ms": 7.022, + "requests": 79017, + "response_bytes": 46926457926, + "rps": 15798.369271558402, + "seconds": 5.001592167, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 593878, + "server_cpu_seconds": 46.45000000000002, + "server_cpu_us_per_request": 587.848184567878, + "server_cpu_percent_one_core": 925.85034194932, + "peak_sampled_rss_mib": 854.984375, + "mib_per_second": 8947.66230225998 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 315.069, + "p95_ms": 1589.008, + "p99_ms": 3015.586, + "requests": 303, + "response_bytes": 3130139682, + "rps": 58.10809534464501, + "seconds": 5.21441975, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 10330494, + "server_cpu_seconds": 42.99, + "server_cpu_us_per_request": 141881.18811881187, + "server_cpu_percent_one_core": 821.4076985615169, + "peak_sampled_rss_mib": 11573.828125, + "mib_per_second": 572.4767020314056 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 68.94, + "p95_ms": 426.809, + "p99_ms": 824.978, + "requests": 1452, + "response_bytes": 15225808488, + "rps": 285.87203239934695, + "seconds": 5.079195708, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "body", + "round": 2, + "response_body_bytes": 10486094, + "server_cpu_seconds": 47.84000000000002, + "server_cpu_us_per_request": 32947.658402203866, + "server_cpu_percent_one_core": 938.0278811809812, + "peak_sampled_rss_mib": 11730.90625, + "mib_per_second": 2858.8113820177055 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 77.838, + "p95_ms": 429.447, + "p99_ms": 714.683, + "requests": 1304, + "response_bytes": 13673866576, + "rps": 256.7390893261394, + "seconds": 5.079086334, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 10486094, + "server_cpu_seconds": 34.41, + "server_cpu_us_per_request": 26388.036809815952, + "server_cpu_percent_one_core": 673.375679264154, + "peak_sampled_rss_mib": 11322.859375, + "mib_per_second": 2567.4726716502137 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 106.157, + "p95_ms": 1527.262, + "p99_ms": 3233.171, + "requests": 598, + "response_bytes": 6270684212, + "rps": 99.96016149611833, + "seconds": 5.982383292, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 10486094, + "server_cpu_seconds": 31.150000000000006, + "server_cpu_us_per_request": 52090.301003344495, + "server_cpu_percent_one_core": 516.9667756379094, + "peak_sampled_rss_mib": 12586.484375, + "mib_per_second": 999.6334549937034 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 126.656, + "p95_ms": 1210.918, + "p99_ms": 1696.597, + "requests": 542, + "response_bytes": 5683462948, + "rps": 105.82541320662594, + "seconds": 5.121643125, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 10486094, + "server_cpu_seconds": 33.44999999999999, + "server_cpu_us_per_request": 61715.867158671565, + "server_cpu_percent_one_core": 649.3346774680866, + "peak_sampled_rss_mib": 12595.359375, + "mib_per_second": 1058.2878403411112 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 116.687, + "p95_ms": 1120.498, + "p99_ms": 1650.813, + "requests": 646, + "response_bytes": 6774016724, + "rps": 126.17788816498287, + "seconds": 5.119756, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "disabled", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 10486094, + "server_cpu_seconds": 33.35000000000002, + "server_cpu_us_per_request": 51625.38699690406, + "server_cpu_percent_one_core": 648.1694513619503, + "peak_sampled_rss_mib": 12632.921875, + "mib_per_second": 1261.8190727419833 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 228.419, + "p95_ms": 1170.578, + "p99_ms": 3641.239, + "requests": 416, + "response_bytes": 247053248, + "rps": 78.1611102039266, + "seconds": 5.322339958, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 593878, + "server_cpu_seconds": 51.30000000000001, + "server_cpu_us_per_request": 123317.30769230773, + "server_cpu_percent_one_core": 959.818431542946, + "peak_sampled_rss_mib": 12661.875, + "mib_per_second": 44.26781063622238 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 297.816, + "p95_ms": 1976.903, + "p99_ms": 2518.437, + "requests": 314, + "response_bytes": 3243775116, + "rps": 57.49795760204689, + "seconds": 5.461063542, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 10330494, + "server_cpu_seconds": 33.15, + "server_cpu_us_per_request": 105573.24840764332, + "server_cpu_percent_one_core": 603.756916149216, + "peak_sampled_rss_mib": 10911.984375, + "mib_per_second": 566.465669651222 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 76.588, + "p95_ms": 427.52, + "p99_ms": 860.297, + "requests": 1263, + "response_bytes": 13243936722, + "rps": 247.23517791213905, + "seconds": 5.108496334, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "body", + "round": 3, + "response_body_bytes": 10486094, + "server_cpu_seconds": 37.719999999999985, + "server_cpu_us_per_request": 29865.39984164686, + "server_cpu_percent_one_core": 734.718495539727, + "peak_sampled_rss_mib": 11131.375, + "mib_per_second": 2472.4305302557123 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 76.85, + "p95_ms": 266.655, + "p99_ms": 422.477, + "requests": 1535, + "response_bytes": 16096154290, + "rps": 301.57381005975583, + "seconds": 5.089964542, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 10486094, + "server_cpu_seconds": 33.92, + "server_cpu_us_per_request": 22097.71986970684, + "server_cpu_percent_one_core": 663.2037039394953, + "peak_sampled_rss_mib": 10073.71875, + "mib_per_second": 3015.834160065408 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 126.253, + "p95_ms": 798.612, + "p99_ms": 2393.254, + "requests": 742, + "response_bytes": 7780681748, + "rps": 101.86878421939956, + "seconds": 7.28388, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 10486094, + "server_cpu_seconds": 37.130000000000024, + "server_cpu_us_per_request": 50040.43126684639, + "server_cpu_percent_one_core": 501.4747421379661, + "peak_sampled_rss_mib": 12571.34375, + "mib_per_second": 1018.7202901748088 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 104.99, + "p95_ms": 760.829, + "p99_ms": 1279.839, + "requests": 882, + "response_bytes": 9248734908, + "rps": 172.79763726808127, + "seconds": 5.104236458, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 10486094, + "server_cpu_seconds": 40.400000000000006, + "server_cpu_us_per_request": 45804.98866213153, + "server_cpu_percent_one_core": 788.0521028555902, + "peak_sampled_rss_mib": 12610.671875, + "mib_per_second": 1728.0314134321247 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 94.733, + "p95_ms": 304.433, + "p99_ms": 2781.562, + "requests": 1040, + "response_bytes": 10905537760, + "rps": 193.83430021690629, + "seconds": 5.365407458, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "disabled", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 10486094, + "server_cpu_seconds": 44.94, + "server_cpu_us_per_request": 43211.53846153846, + "server_cpu_percent_one_core": 832.513441284798, + "peak_sampled_rss_mib": 12665.4375, + "mib_per_second": 1938.4047436701771 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 380.765, + "p95_ms": 1814.345, + "p99_ms": 2139.137, + "requests": 295, + "response_bytes": 175194010, + "rps": 53.566072774775684, + "seconds": 5.50721725, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 593878, + "server_cpu_seconds": 38.01999999999998, + "server_cpu_us_per_request": 128881.35593220334, + "server_cpu_percent_one_core": 687.8835459289048, + "peak_sampled_rss_mib": 11868.46875, + "mib_per_second": 30.338012854898675 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 37.425, + "p95_ms": 41.025, + "p99_ms": 57.089, + "requests": 4293, + "response_bytes": 44348810742, + "rps": 854.9365256857304, + "seconds": 5.021425417, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 10330494, + "server_cpu_seconds": 8.43, + "server_cpu_us_per_request": 1963.6617749825298, + "server_cpu_percent_one_core": 167.32556483581695, + "peak_sampled_rss_mib": 435.671875, + "mib_per_second": 8422.772072770389 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 39.291, + "p95_ms": 41.846, + "p99_ms": 43.357, + "requests": 4106, + "response_bytes": 43055901964, + "rps": 817.3210217293944, + "seconds": 5.023729833, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "body", + "round": 3, + "response_body_bytes": 10486094, + "server_cpu_seconds": 8.39, + "server_cpu_us_per_request": 2043.351193375548, + "server_cpu_percent_one_core": 166.4746137589825, + "peak_sampled_rss_mib": 435.953125, + "mib_per_second": 8173.470556288216 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 38.119, + "p95_ms": 40.753, + "p99_ms": 46.151, + "requests": 4228, + "response_bytes": 44335205432, + "rps": 842.8567121162397, + "seconds": 5.01627375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 10486094, + "server_cpu_seconds": 8.099999999999998, + "server_cpu_us_per_request": 1915.7994323557234, + "server_cpu_percent_one_core": 160.94582365118185, + "peak_sampled_rss_mib": 436.0, + "mib_per_second": 8428.835593969181 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 39.22, + "p95_ms": 41.403, + "p99_ms": 42.518, + "requests": 4103, + "response_bytes": 43024443682, + "rps": 816.8361957367649, + "seconds": 5.023038917, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 10486094, + "server_cpu_seconds": 11.030000000000001, + "server_cpu_us_per_request": 2688.276870582501, + "server_cpu_percent_one_core": 218.83628893049135, + "peak_sampled_rss_mib": 745.375, + "mib_per_second": 8168.622141931645 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 38.721, + "p95_ms": 41.575, + "p99_ms": 44.461, + "requests": 4194, + "response_bytes": 43978678236, + "rps": 835.0458842183197, + "seconds": 5.0224785, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 10486094, + "server_cpu_seconds": 12.529999999999994, + "server_cpu_us_per_request": 2987.601335240819, + "server_cpu_percent_one_core": 248.6410401406752, + "peak_sampled_rss_mib": 825.8125, + "mib_per_second": 8350.724827028673 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 38.854, + "p95_ms": 41.483, + "p99_ms": 50.876, + "requests": 4186, + "response_bytes": 43894789484, + "rps": 833.9808547501857, + "seconds": 5.019299875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go", + "journal": "disabled", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 10486094, + "server_cpu_seconds": 11.129999999999995, + "server_cpu_us_per_request": 2658.86287625418, + "server_cpu_percent_one_core": 220.9457277669879, + "peak_sampled_rss_mib": 896.40625, + "mib_per_second": 8340.074193106455 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.73, + "p95_ms": 4.202, + "p99_ms": 7.444, + "requests": 78049, + "response_bytes": 46351584022, + "rps": 15603.669967182565, + "seconds": 5.001964292, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 593878, + "server_cpu_seconds": 44.599999999999994, + "server_cpu_us_per_request": 571.4358928365513, + "server_cpu_percent_one_core": 888.7496351391306, + "peak_sampled_rss_mib": 898.25, + "mib_per_second": 8837.391197939345 + } + ] +} \ No newline at end of file diff --git a/testdata/reports/benchmark-large-json-1mib.json b/testdata/reports/benchmark-large-json-1mib.json new file mode 100644 index 0000000..5be394a --- /dev/null +++ b/testdata/reports/benchmark-large-json-1mib.json @@ -0,0 +1,2728 @@ +{ + "platform": "macOS-27.0.1-arm64-arm-64bit-Mach-O", + "machine": "arm64", + "logical_cpus": 14, + "go_version": "go version go1.27.1 darwin/arm64", + "java_version": "openjdk version \"27\" 2026-09-15\nOpenJDK Runtime Environment Homebrew (build 27)\nOpenJDK 64-Bit Server VM Homebrew (build 27, mixed mode, sharing)", + "binaries": { + "java": { + "path": "wiremock.jar", + "sha256": "3a53dec6c814ff73da4abb0bc51624215ea2b913beec8d19aa6d54e4c62161d3" + }, + "go": { + "path": "breakmock-release", + "sha256": "27907252cfd00980e64b1b3af9820acf71556691057c846fc1e55720248c4405" + } + }, + "driver_sha256": "d1c95028a7901028d5f58236ab80683283a72a9f7d570f0b20cd9c12d99f0224", + "source_revision": "68cd31176154240eb238d4e1a743b414cf5fdfb9", + "source_dirty": false, + "settings": { + "size": 1048576, + "rounds": 3, + "duration": "5s", + "warmup": "2s", + "concurrency": 32, + "response_body_bytes": { + "jsonBody": 1033072, + "body": 1048747, + "bodyFileName": 1048747, + "templateBody": 1048747, + "templateFile": 1048747, + "templateHelper": 1048747, + "jsonBodyGzip": 60219 + } + }, + "notes": [ + "Unlimited-rate closed loop with persistent connections; driver and servers share the host.", + "Every response is compared byte-for-byte with the first server's response for that workload.", + "With capped journals, the newest logged event (ids, timings and client details removed) must be identical across servers.", + "Server CPU is the ps user+system delta over the measurement window divided by completed requests." + ], + "journal_differences": [ + { + "server": "go", + "workload": "jsonBodyGzip", + "differing_event_fields": "response" + }, + { + "server": "go", + "workload": "templateBody", + "differing_event_fields": "responseDefinition" + }, + { + "server": "go", + "workload": "templateFile", + "differing_event_fields": "responseDefinition" + }, + { + "server": "go", + "workload": "templateHelper", + "differing_event_fields": "responseDefinition" + } + ], + "summary": { + "disabled/jsonBody": { + "java": { + "rps": [ + 984.7018117029211, + 1079.036530798075, + 1083.6861221952202 + ], + "cpu_us": [ + 9476.026704430507, + 9001.845018450185, + 8959.750045947434 + ], + "p99_ms": [ + 143.496, + 114.158, + 120.711 + ], + "rss": [ + 5138.5, + 4415.3125, + 3143.140625 + ] + }, + "go": { + "rps": [ + 10450.940573906648, + 10479.153464644614, + 10575.161065208296 + ], + "cpu_us": [ + 267.4113888942023, + 272.9509603830088, + 268.42085365392614 + ], + "p99_ms": [ + 3.532, + 3.512, + 3.528 + ], + "rss": [ + 59.234375, + 59.984375, + 59.46875 + ] + } + }, + "disabled/body": { + "java": { + "rps": [ + 1867.389330182525, + 3058.1008718418166, + 3395.736516506899 + ], + "cpu_us": [ + 3227.59799209655, + 2699.791068164011, + 2719.14868598977 + ], + "p99_ms": [ + 158.817, + 90.026, + 69.215 + ], + "rss": [ + 4438.609375, + 3977.546875, + 2850.296875 + ] + }, + "go": { + "rps": [ + 10377.211047877212, + 10364.203821427656, + 10329.42254359632 + ], + "cpu_us": [ + 278.93357990445367, + 281.4049028873415, + 281.37397194000965 + ], + "p99_ms": [ + 3.517, + 3.56, + 3.526 + ], + "rss": [ + 61.5625, + 61.265625, + 61.9375 + ] + } + }, + "disabled/bodyFileName": { + "java": { + "rps": [ + 3042.4663283414425, + 3508.651458232073, + 3447.0717912960886 + ], + "cpu_us": [ + 2185.182754773935, + 2251.195627419722, + 2232.199756676902 + ], + "p99_ms": [ + 60.805, + 35.38, + 34.077 + ], + "rss": [ + 2822.703125, + 3516.5625, + 2857.828125 + ] + }, + "go": { + "rps": [ + 10474.378329173118, + 10496.804203872794, + 10507.637427239008 + ], + "cpu_us": [ + 278.27613848913995, + 284.3213802822266, + 284.9805003329212 + ], + "p99_ms": [ + 3.518, + 3.531, + 3.519 + ], + "rss": [ + 61.84375, + 61.515625, + 62.171875 + ] + } + }, + "disabled/templateBody": { + "java": { + "rps": [ + 2430.2400943038056, + 2512.6049059362613, + 2579.4257714098767 + ], + "cpu_us": [ + 3374.394350004106, + 3295.725409184808, + 3489.2002787024844 + ], + "p99_ms": [ + 95.193, + 96.806, + 77.497 + ], + "rss": [ + 2706.34375, + 3954.03125, + 4214.640625 + ] + }, + "go": { + "rps": [ + 11311.813314499635, + 11281.906462927524, + 11564.067500200896 + ], + "cpu_us": [ + 489.1669317499027, + 489.9268210571078, + 484.0605767236014 + ], + "p99_ms": [ + 6.795, + 6.532, + 7.179 + ], + "rss": [ + 130.453125, + 123.015625, + 129.640625 + ] + } + }, + "disabled/templateFile": { + "java": { + "rps": [ + 2480.451065767836, + 2371.5739913328916, + 2609.375668547093 + ], + "cpu_us": [ + 3665.3258246178602, + 3581.22318499201, + 3682.680538555695 + ], + "p99_ms": [ + 65.886, + 80.748, + 60.028 + ], + "rss": [ + 2718.453125, + 3965.515625, + 3134.5 + ] + }, + "go": { + "rps": [ + 11292.60050940446, + 11225.322607423108, + 10496.45840239331 + ], + "cpu_us": [ + 515.9657320872273, + 507.8709309779901, + 495.2003656864239 + ], + "p99_ms": [ + 6.995, + 7.334, + 10.541 + ], + "rss": [ + 131.1875, + 137.328125, + 130.265625 + ] + } + }, + "disabled/templateHelper": { + "java": { + "rps": [ + 2565.888429512358, + 2503.5950884010913, + 2667.36319378614 + ], + "cpu_us": [ + 3498.2497082847117, + 3497.289540816327, + 3423.099940155595 + ], + "p99_ms": [ + 76.513, + 86.153, + 75.766 + ], + "rss": [ + 2731.96875, + 4025.625, + 3056.859375 + ] + }, + "go": { + "rps": [ + 11333.61196573831, + 11147.172350039084, + 11343.4721153844 + ], + "cpu_us": [ + 508.0171455786635, + 503.90933218563936, + 526.3436123348018 + ], + "p99_ms": [ + 6.437, + 7.197, + 6.559 + ], + "rss": [ + 131.890625, + 141.984375, + 130.984375 + ] + } + }, + "disabled/jsonBodyGzip": { + "java": { + "rps": [ + 967.598371572983, + 912.0330239680737, + 1034.5097380763027 + ], + "cpu_us": [ + 11257.706535141795, + 11068.320278503048, + 11079.261254328594 + ], + "p99_ms": [ + 93.657, + 101.924, + 94.718 + ], + "rss": [ + 2746.703125, + 3013.6875, + 3055.140625 + ] + }, + "go": { + "rps": [ + 75638.1232426248, + 72143.28674076505, + 74793.96122086361 + ], + "cpu_us": [ + 78.98597655269035, + 76.16942058994175, + 80.88962549119194 + ], + "p99_ms": [ + 1.086, + 1.283, + 1.065 + ], + "rss": [ + 132.4375, + 144.953125, + 131.53125 + ] + } + }, + "capped/jsonBody": { + "java": { + "rps": [ + 608.1726303677503, + 878.4465081850897, + 1212.78046276208 + ], + "cpu_us": [ + 13314.808761033017, + 10507.936507936507, + 9146.56162809782 + ], + "p99_ms": [ + 368.795, + 184.847, + 115.45 + ], + "rss": [ + 9067.578125, + 9747.390625, + 6500.015625 + ] + }, + "go": { + "rps": [ + 10435.731435411833, + 10476.536807559354, + 10588.009997749681 + ], + "cpu_us": [ + 343.0705871085144, + 335.0761363202687, + 329.07281892499105 + ], + "p99_ms": [ + 3.975, + 3.79, + 3.871 + ], + "rss": [ + 2452.625, + 2316.96875, + 2383.359375 + ] + } + }, + "capped/body": { + "java": { + "rps": [ + 1022.0715657314955, + 1656.7680157147267, + 2187.98931179186 + ], + "cpu_us": [ + 6317.376554843576, + 4761.9047619047615, + 3681.8717692935516 + ], + "p99_ms": [ + 288.119, + 183.14, + 137.472 + ], + "rss": [ + 9334.484375, + 11835.609375, + 11295.15625 + ] + }, + "go": { + "rps": [ + 10558.842980758067, + 10244.740007895776, + 10329.737877085106 + ], + "cpu_us": [ + 326.410057367893, + 341.0931371592483, + 334.7976699630367 + ], + "p99_ms": [ + 3.686, + 3.825, + 3.647 + ], + "rss": [ + 2453.125, + 2317.21875, + 2383.484375 + ] + } + }, + "capped/bodyFileName": { + "java": { + "rps": [ + 2511.6216991162582, + 2117.430823968414, + 2081.2165965159957 + ], + "cpu_us": [ + 3335.18533216922, + 3949.62739364211, + 3219.007472695918 + ], + "p99_ms": [ + 141.857, + 152.377, + 118.689 + ], + "rss": [ + 10974.0625, + 9514.359375, + 10251.8125 + ] + }, + "go": { + "rps": [ + 10474.818861576781, + 10240.86201447431, + 10601.331432723831 + ], + "cpu_us": [ + 332.80537373814485, + 344.0939964087751, + 333.53444700026404 + ], + "p99_ms": [ + 5.065, + 3.678, + 4.074 + ], + "rss": [ + 2453.234375, + 2317.359375, + 2383.609375 + ] + } + }, + "capped/templateBody": { + "java": { + "rps": [ + 1417.521521545949, + 1450.4508688592516, + 1168.667880304786 + ], + "cpu_us": [ + 4992.959729653619, + 5354.439091534757, + 6802.663024923186 + ], + "p99_ms": [ + 185.692, + 152.62, + 272.184 + ], + "rss": [ + 12029.265625, + 11863.890625, + 11978.90625 + ] + }, + "go": { + "rps": [ + 11513.930186034208, + 10492.78531058031, + 10396.507075987814 + ], + "cpu_us": [ + 362.3200986093992, + 390.72620589804166, + 394.6862503844971 + ], + "p99_ms": [ + 6.352, + 4.892, + 5.446 + ], + "rss": [ + 4064.53125, + 2764.640625, + 4101.984375 + ] + } + }, + "capped/templateFile": { + "java": { + "rps": [ + 2244.205445368841, + 1946.3682551232723, + 1916.1694815874732 + ], + "cpu_us": [ + 4224.713103816384, + 4393.8461538461515, + 4306.6986144390075 + ], + "p99_ms": [ + 82.464, + 90.115, + 84.779 + ], + "rss": [ + 12012.78125, + 12014.421875, + 12071.90625 + ] + }, + "go": { + "rps": [ + 10420.343766803056, + 10256.125408123717, + 10445.76546845104 + ], + "cpu_us": [ + 428.91945291669094, + 427.2904483430799, + 431.90385976998283 + ], + "p99_ms": [ + 4.226, + 4.546, + 6.273 + ], + "rss": [ + 4064.609375, + 3080.515625, + 4102.0625 + ] + } + }, + "capped/templateHelper": { + "java": { + "rps": [ + 1648.5165955284556, + 1105.1300896695218, + 1907.2610760857765 + ], + "cpu_us": [ + 4723.726977248105, + 6788.89284442863, + 4125.523012552301 + ], + "p99_ms": [ + 157.19, + 185.086, + 128.127 + ], + "rss": [ + 11985.421875, + 11626.671875, + 11993.390625 + ] + }, + "go": { + "rps": [ + 10551.489425453905, + 10313.218381254797, + 10243.3897815979 + ], + "cpu_us": [ + 407.9042097684817, + 413.048534656536, + 405.31574428225707 + ], + "p99_ms": [ + 4.35, + 4.517, + 4.462 + ], + "rss": [ + 4064.96875, + 3284.046875, + 4102.484375 + ] + } + }, + "capped/jsonBodyGzip": { + "java": { + "rps": [ + 528.9619160161292, + 738.6449555467143, + 869.8711485289485 + ], + "cpu_us": [ + 15887.218045112779, + 13049.798115746975, + 11120.512234164187 + ], + "p99_ms": [ + 368.709, + 175.513, + 118.184 + ], + "rss": [ + 9909.921875, + 9271.328125, + 11443.96875 + ] + }, + "go": { + "rps": [ + 61815.8820280146, + 60708.70340829969, + 61355.12878486319 + ], + "cpu_us": [ + 99.91590115150726, + 105.05931405160095, + 106.78963061932775 + ], + "p99_ms": [ + 1.685, + 1.687, + 1.625 + ], + "rss": [ + 4070.078125, + 3290.796875, + 4109.546875 + ] + } + } + }, + "results": [ + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 16.449, + "p95_ms": 94.565, + "p99_ms": 143.496, + "requests": 4943, + "response_bytes": 5106474896, + "rps": 984.7018117029211, + "seconds": 5.01979375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 1033072, + "server_cpu_seconds": 46.84, + "server_cpu_us_per_request": 9476.026704430507, + "server_cpu_percent_one_core": 930.9199373141165, + "peak_sampled_rss_mib": 5138.5, + "mib_per_second": 970.142240542946 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 5.105, + "p95_ms": 72.985, + "p99_ms": 158.817, + "requests": 9363, + "response_bytes": 9819418161, + "rps": 1867.389330182525, + "seconds": 5.01395175, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "body", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 30.22, + "server_cpu_us_per_request": 3227.59799209655, + "server_cpu_percent_one_core": 599.1062373792668, + "peak_sampled_rss_mib": 4438.609375, + "mib_per_second": 1867.6938608750654 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 7.937, + "p95_ms": 28.986, + "p99_ms": 60.805, + "requests": 15239, + "response_bytes": 15981855533, + "rps": 3042.4663283414425, + "seconds": 5.008765375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 33.3, + "server_cpu_us_per_request": 2185.182754773935, + "server_cpu_percent_one_core": 662.8977326131884, + "peak_sampled_rss_mib": 2822.703125, + "mib_per_second": 3042.9624886027364 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 6.584, + "p95_ms": 42.883, + "p99_ms": 95.193, + "requests": 12177, + "response_bytes": 12770592219, + "rps": 2430.2400943038056, + "seconds": 5.010616041, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 41.09, + "server_cpu_us_per_request": 3374.394350004106, + "server_cpu_percent_one_core": 817.8065687447523, + "peak_sampled_rss_mib": 2706.34375, + "mib_per_second": 2430.636413746675 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 6.38, + "p95_ms": 39.598, + "p99_ms": 65.886, + "requests": 12430, + "response_bytes": 13035925210, + "rps": 2480.451065767836, + "seconds": 5.011185333, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 45.56, + "server_cpu_us_per_request": 3665.3258246178602, + "server_cpu_percent_one_core": 906.6636669969777, + "peak_sampled_rss_mib": 2718.453125, + "mib_per_second": 2480.85557353098 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 5.508, + "p95_ms": 44.119, + "p99_ms": 76.513, + "requests": 12855, + "response_bytes": 13481642685, + "rps": 2565.888429512358, + "seconds": 5.009960625, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "disabled", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 44.96999999999997, + "server_cpu_us_per_request": 3498.2497082847117, + "server_cpu_percent_one_core": 894.8756355181296, + "peak_sampled_rss_mib": 2731.96875, + "mib_per_second": 2566.30687025623 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 25.751, + "p95_ms": 76.483, + "p99_ms": 93.657, + "requests": 4866, + "response_bytes": 293025654, + "rps": 967.598371572983, + "seconds": 5.028946041, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 60219, + "server_cpu_seconds": 54.77999999999997, + "server_cpu_us_per_request": 11257.706535141795, + "server_cpu_percent_one_core": 1086.7684845954404, + "peak_sampled_rss_mib": 2746.703125, + "mib_per_second": 55.56851037764879 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.071, + "p95_ms": 3.375, + "p99_ms": 3.532, + "requests": 52279, + "response_bytes": 54007971088, + "rps": 10450.940573906648, + "seconds": 5.002324875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 1033072, + "server_cpu_seconds": 13.98, + "server_cpu_us_per_request": 267.4113888942023, + "server_cpu_percent_one_core": 278.7033416761375, + "peak_sampled_rss_mib": 59.234375, + "mib_per_second": 10296.415405814065 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.079, + "p95_ms": 3.381, + "p99_ms": 3.517, + "requests": 51912, + "response_bytes": 54442554264, + "rps": 10377.211047877212, + "seconds": 5.002500167, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "body", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 14.48, + "server_cpu_us_per_request": 278.93357990445367, + "server_cpu_percent_one_core": 288.6349298887632, + "peak_sampled_rss_mib": 61.5625, + "mib_per_second": 10378.903345897754 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.056, + "p95_ms": 3.371, + "p99_ms": 3.518, + "requests": 52394, + "response_bytes": 54948050318, + "rps": 10474.378329173118, + "seconds": 5.002110708, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 14.579999999999998, + "server_cpu_us_per_request": 278.27613848913995, + "server_cpu_percent_one_core": 290.6716746078685, + "peak_sampled_rss_mib": 61.84375, + "mib_per_second": 10476.086473069496 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.777, + "p95_ms": 4.725, + "p99_ms": 6.795, + "requests": 56586, + "response_bytes": 59344397742, + "rps": 11311.813314499635, + "seconds": 5.002381, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 27.679999999999993, + "server_cpu_us_per_request": 489.1669317499027, + "server_cpu_percent_one_core": 551.7144101854983, + "peak_sampled_rss_mib": 130.453125, + "mib_per_second": 11313.65802587657 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.768, + "p95_ms": 4.857, + "p99_ms": 6.995, + "requests": 56496, + "response_bytes": 59250010512, + "rps": 11292.60050940446, + "seconds": 5.002922042, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 29.14999999999999, + "server_cpu_us_per_request": 515.9657320872273, + "server_cpu_percent_one_core": 580.9446083441314, + "peak_sampled_rss_mib": 131.1875, + "mib_per_second": 11294.442087589645 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.792, + "p95_ms": 4.602, + "p99_ms": 6.437, + "requests": 56691, + "response_bytes": 59454516177, + "rps": 11333.61196573831, + "seconds": 5.002024083, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go", + "journal": "disabled", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 28.80000000000001, + "server_cpu_us_per_request": 508.0171455786635, + "server_cpu_percent_one_core": 574.0429632010068, + "peak_sampled_rss_mib": 131.890625, + "mib_per_second": 11335.460232002406 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.394, + "p95_ms": 0.726, + "p99_ms": 1.086, + "requests": 378295, + "response_bytes": 22780546605, + "rps": 75638.1232426248, + "seconds": 5.001380042, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 60219, + "server_cpu_seconds": 29.879999999999995, + "server_cpu_us_per_request": 78.98597655269035, + "server_cpu_percent_one_core": 594.0005349615533, + "peak_sampled_rss_mib": 132.4375, + "mib_per_second": 4343.845504329322 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.06, + "p95_ms": 3.376, + "p99_ms": 3.512, + "requests": 52427, + "response_bytes": 54160865744, + "rps": 10479.153464644614, + "seconds": 5.002980458, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 1033072, + "server_cpu_seconds": 14.310000000000002, + "server_cpu_us_per_request": 272.9509603830088, + "server_cpu_percent_one_core": 285.23890888817925, + "peak_sampled_rss_mib": 59.984375, + "mib_per_second": 10324.211147334425 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.089, + "p95_ms": 3.411, + "p99_ms": 3.56, + "requests": 51847, + "response_bytes": 54374385709, + "rps": 10364.203821427656, + "seconds": 5.002506791, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "body", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 14.589999999999996, + "server_cpu_us_per_request": 281.4049028873415, + "server_cpu_percent_one_core": 290.8495255642233, + "peak_sampled_rss_mib": 61.265625, + "mib_per_second": 10365.893998251715 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.058, + "p95_ms": 3.379, + "p99_ms": 3.531, + "requests": 52511, + "response_bytes": 55070753717, + "rps": 10496.804203872794, + "seconds": 5.002570209, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 14.93, + "server_cpu_us_per_request": 284.3213802822266, + "server_cpu_percent_one_core": 297.61402705144707, + "peak_sampled_rss_mib": 61.515625, + "mib_per_second": 10498.516004942876 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.793, + "p95_ms": 4.5, + "p99_ms": 6.532, + "requests": 56437, + "response_bytes": 59188134439, + "rps": 11281.906462927524, + "seconds": 5.002434667, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 27.64999999999999, + "server_cpu_us_per_request": 489.9268210571078, + "server_cpu_percent_one_core": 551.0605743713946, + "peak_sampled_rss_mib": 123.015625, + "mib_per_second": 11283.746297145703 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.754, + "p95_ms": 5.231, + "p99_ms": 7.334, + "requests": 56156, + "response_bytes": 58893436532, + "rps": 11225.322607423108, + "seconds": 5.002617917, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 28.52000000000001, + "server_cpu_us_per_request": 507.8709309779901, + "server_cpu_percent_one_core": 568.3319490455314, + "peak_sampled_rss_mib": 137.328125, + "mib_per_second": 11227.153214041864 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.808, + "p95_ms": 4.95, + "p99_ms": 7.197, + "requests": 55764, + "response_bytes": 58482327708, + "rps": 11147.172350039084, + "seconds": 5.00252425, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go", + "journal": "disabled", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 28.099999999999994, + "server_cpu_us_per_request": 503.90933218563936, + "server_cpu_percent_one_core": 559.983657436702, + "peak_sampled_rss_mib": 141.984375, + "mib_per_second": 11148.990212046088 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.393, + "p95_ms": 0.777, + "p99_ms": 1.283, + "requests": 363663, + "response_bytes": 21899422197, + "rps": 72143.28674076505, + "seconds": 5.04084325, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 60219, + "server_cpu_seconds": 27.69999999999999, + "server_cpu_us_per_request": 76.16942058994175, + "server_cpu_percent_one_core": 545.9105473844899, + "peak_sampled_rss_mib": 144.953125, + "mib_per_second": 4143.139442674761 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 15.299, + "p95_ms": 85.757, + "p99_ms": 114.158, + "requests": 5420, + "response_bytes": 5599250240, + "rps": 1079.036530798075, + "seconds": 5.022999542, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 1033072, + "server_cpu_seconds": 48.790000000000006, + "server_cpu_us_per_request": 9001.845018450185, + "server_cpu_percent_one_core": 968.998101723952, + "peak_sampled_rss_mib": 4415.3125, + "mib_per_second": 1063.082148499135 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 4.715, + "p95_ms": 33.116, + "p99_ms": 90.026, + "requests": 15316, + "response_bytes": 16062609052, + "rps": 3058.1008718418166, + "seconds": 5.008337083, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "body", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 41.349999999999994, + "server_cpu_us_per_request": 2699.791068164011, + "server_cpu_percent_one_core": 823.2279899262744, + "peak_sampled_rss_mib": 3977.546875, + "mib_per_second": 3058.5995817580124 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 8.528, + "p95_ms": 19.373, + "p99_ms": 35.38, + "requests": 17564, + "response_bytes": 18420192308, + "rps": 3508.651458232073, + "seconds": 5.005911875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 39.53999999999999, + "server_cpu_us_per_request": 2251.195627419722, + "server_cpu_percent_one_core": 787.7017197428833, + "peak_sampled_rss_mib": 3516.5625, + "mib_per_second": 3509.2236431756132 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 5.518, + "p95_ms": 44.247, + "p99_ms": 96.806, + "requests": 12586, + "response_bytes": 13199529742, + "rps": 2512.6049059362613, + "seconds": 5.009144084, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 41.47999999999999, + "server_cpu_us_per_request": 3295.725409184808, + "server_cpu_percent_one_core": 825.4489067645512, + "peak_sampled_rss_mib": 3954.03125, + "mib_per_second": 2513.014657293259 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 6.21, + "p95_ms": 45.386, + "p99_ms": 80.748, + "requests": 11887, + "response_bytes": 12466455589, + "rps": 2371.5739913328916, + "seconds": 5.012283, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 42.57000000000002, + "server_cpu_us_per_request": 3581.22318499201, + "server_cpu_percent_one_core": 846.8951108246889, + "peak_sampled_rss_mib": 3965.515625, + "mib_per_second": 2371.960743606945 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 5.532, + "p95_ms": 45.704, + "p99_ms": 86.153, + "requests": 12544, + "response_bytes": 13155482368, + "rps": 2503.5950884010913, + "seconds": 5.010394875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "disabled", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 43.870000000000005, + "server_cpu_us_per_request": 3497.289540816327, + "server_cpu_percent_one_core": 873.3936486701252, + "peak_sampled_rss_mib": 4025.625, + "mib_per_second": 2504.003370452289 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 27.003, + "p95_ms": 81.075, + "p99_ms": 101.924, + "requests": 4596, + "response_bytes": 276766524, + "rps": 912.0330239680737, + "seconds": 5.039291209, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 60219, + "server_cpu_seconds": 50.870000000000005, + "server_cpu_us_per_request": 11068.320278503048, + "server_cpu_percent_one_core": 1007.1966198269668, + "peak_sampled_rss_mib": 3013.6875, + "mib_per_second": 52.37743060143798 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 14.625, + "p95_ms": 89.48, + "p99_ms": 120.711, + "requests": 5441, + "response_bytes": 5620944752, + "rps": 1083.6861221952202, + "seconds": 5.0208265, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 1033072, + "server_cpu_seconds": 48.74999999999999, + "server_cpu_us_per_request": 8959.750045947434, + "server_cpu_percent_one_core": 968.7528037945567, + "peak_sampled_rss_mib": 3143.140625, + "mib_per_second": 1067.6629921230895 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 4.109, + "p95_ms": 30.007, + "p99_ms": 69.215, + "requests": 17009, + "response_bytes": 17838137723, + "rps": 3395.736516506899, + "seconds": 5.008928083, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "body", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 46.25, + "server_cpu_us_per_request": 2719.14868598977, + "server_cpu_percent_one_core": 920.9082128858678, + "peak_sampled_rss_mib": 2850.296875, + "mib_per_second": 3396.2902874727833 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 8.805, + "p95_ms": 19.307, + "p99_ms": 34.077, + "requests": 17261, + "response_bytes": 18102421967, + "rps": 3447.0717912960886, + "seconds": 5.0074385, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 38.53, + "server_cpu_us_per_request": 2232.199756676902, + "server_cpu_percent_one_core": 767.4098644448378, + "peak_sampled_rss_mib": 2857.828125, + "mib_per_second": 3447.6339339317315 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 5.689, + "p95_ms": 41.503, + "p99_ms": 77.497, + "requests": 12917, + "response_bytes": 13546664999, + "rps": 2579.4257714098767, + "seconds": 5.007703708, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 45.06999999999999, + "server_cpu_us_per_request": 3489.2002787024844, + "server_cpu_percent_one_core": 897.8142943639446, + "peak_sampled_rss_mib": 4214.640625, + "mib_per_second": 2579.8464198005618 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 6.757, + "p95_ms": 35.851, + "p99_ms": 60.028, + "requests": 13072, + "response_bytes": 13709220784, + "rps": 2609.375668547093, + "seconds": 5.009627459, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 48.14000000000004, + "server_cpu_us_per_request": 3682.680538555695, + "server_cpu_percent_one_core": 958.4014643895797, + "peak_sampled_rss_mib": 3134.5, + "mib_per_second": 2609.8012011163314 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 5.756, + "p95_ms": 41.513, + "p99_ms": 75.766, + "requests": 13368, + "response_bytes": 14019649896, + "rps": 2667.36319378614, + "seconds": 5.011690958, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "disabled", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 45.75999999999999, + "server_cpu_us_per_request": 3423.099940155595, + "server_cpu_percent_one_core": 910.4547855781502, + "peak_sampled_rss_mib": 3056.859375, + "mib_per_second": 2667.7981828628854 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 21.767, + "p95_ms": 74.541, + "p99_ms": 94.718, + "requests": 5198, + "response_bytes": 313018362, + "rps": 1034.5097380763027, + "seconds": 5.024602291, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 60219, + "server_cpu_seconds": 57.59000000000003, + "server_cpu_us_per_request": 11079.261254328594, + "server_cpu_percent_one_core": 1143.6737785256037, + "peak_sampled_rss_mib": 3055.140625, + "mib_per_second": 59.41118423196494 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.031, + "p95_ms": 3.349, + "p99_ms": 3.528, + "requests": 52902, + "response_bytes": 54651574944, + "rps": 10575.161065208296, + "seconds": 5.002477, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 1033072, + "server_cpu_seconds": 14.2, + "server_cpu_us_per_request": 268.42085365392614, + "server_cpu_percent_one_core": 283.0006398347771, + "peak_sampled_rss_mib": 59.46875, + "mib_per_second": 10418.799201924196 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.088, + "p95_ms": 3.395, + "p99_ms": 3.526, + "requests": 51675, + "response_bytes": 54194001225, + "rps": 10329.42254359632, + "seconds": 5.002699791, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "body", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 14.54, + "server_cpu_us_per_request": 281.37397194000965, + "server_cpu_percent_one_core": 289.83994379141086, + "peak_sampled_rss_mib": 61.9375, + "mib_per_second": 10331.107048348436 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.046, + "p95_ms": 3.355, + "p99_ms": 3.519, + "requests": 52565, + "response_bytes": 55127386055, + "rps": 10507.637427239008, + "seconds": 5.00255175, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 14.980000000000004, + "server_cpu_us_per_request": 284.9805003329212, + "server_cpu_percent_one_core": 298.55317059816184, + "peak_sampled_rss_mib": 62.171875, + "mib_per_second": 10509.350994972829 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.621, + "p95_ms": 5.048, + "p99_ms": 7.179, + "requests": 57844, + "response_bytes": 60663721468, + "rps": 11564.067500200896, + "seconds": 5.002046209, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 28.0, + "server_cpu_us_per_request": 484.0605767236014, + "server_cpu_percent_one_core": 558.0785448347149, + "peak_sampled_rss_mib": 129.640625, + "mib_per_second": 11565.953348763645 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.66, + "p95_ms": 6.538, + "p99_ms": 10.541, + "requests": 52504, + "response_bytes": 55063412488, + "rps": 10496.45840239331, + "seconds": 5.002068125, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 26.0, + "server_cpu_us_per_request": 495.2003656864239, + "server_cpu_percent_one_core": 517.6835300969565, + "peak_sampled_rss_mib": 130.265625, + "mib_per_second": 10498.170147070672 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.744, + "p95_ms": 4.706, + "p99_ms": 6.559, + "requests": 56750, + "response_bytes": 59516392250, + "rps": 11343.4721153844, + "seconds": 5.002877375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go", + "journal": "disabled", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 29.870000000000005, + "server_cpu_us_per_request": 526.3436123348018, + "server_cpu_percent_one_core": 595.1975656952038, + "peak_sampled_rss_mib": 130.984375, + "mib_per_second": 11345.321989625018 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.399, + "p95_ms": 0.722, + "p99_ms": 1.065, + "requests": 374090, + "response_bytes": 22527325710, + "rps": 74793.96122086361, + "seconds": 5.001607, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 60219, + "server_cpu_seconds": 30.25999999999999, + "server_cpu_us_per_request": 80.88962549119194, + "server_cpu_percent_one_core": 601.6284378290019, + "peak_sampled_rss_mib": 131.53125, + "mib_per_second": 4295.365858802019 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 31.169, + "p95_ms": 162.187, + "p99_ms": 368.795, + "requests": 3059, + "response_bytes": 3160167248, + "rps": 608.1726303677503, + "seconds": 5.029821875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 1033072, + "server_cpu_seconds": 40.73, + "server_cpu_us_per_request": 13314.808761033017, + "server_cpu_percent_one_core": 807.9917252628775, + "peak_sampled_rss_mib": 9067.578125, + "mib_per_second": 599.1803318016745 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 11.539, + "p95_ms": 153.681, + "p99_ms": 288.119, + "requests": 5306, + "response_bytes": 5564651582, + "rps": 1022.0715657314955, + "seconds": 5.191417292, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "body", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 33.52000000000001, + "server_cpu_us_per_request": 6317.376554843576, + "server_cpu_percent_one_core": 640.9070440648146, + "peak_sampled_rss_mib": 9334.484375, + "mib_per_second": 1022.2382434331977 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 9.816, + "p95_ms": 25.565, + "p99_ms": 141.857, + "requests": 12599, + "response_bytes": 13213163453, + "rps": 2511.6216991162582, + "seconds": 5.016280917, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 42.02000000000001, + "server_cpu_us_per_request": 3335.18533216922, + "server_cpu_percent_one_core": 835.5803101000718, + "peak_sampled_rss_mib": 10974.0625, + "mib_per_second": 2512.031290133551 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 8.684, + "p95_ms": 97.551, + "p99_ms": 185.692, + "requests": 7102, + "response_bytes": 7448201194, + "rps": 1417.521521545949, + "seconds": 5.010153209, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 35.46000000000001, + "server_cpu_us_per_request": 4992.959729653619, + "server_cpu_percent_one_core": 706.1459833111028, + "peak_sampled_rss_mib": 12029.265625, + "mib_per_second": 1417.752688557386 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 7.026, + "p95_ms": 47.166, + "p99_ms": 82.464, + "requests": 11241, + "response_bytes": 11788965027, + "rps": 2244.205445368841, + "seconds": 5.008899708, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 47.48999999999998, + "server_cpu_us_per_request": 4224.713103816384, + "server_cpu_percent_one_core": 945.7859032203611, + "peak_sampled_rss_mib": 12012.78125, + "mib_per_second": 2244.571426595913 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 6.276, + "p95_ms": 78.247, + "p99_ms": 157.19, + "requests": 8307, + "response_bytes": 8711941329, + "rps": 1648.5165955284556, + "seconds": 5.03907575, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "capped", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 39.24000000000001, + "server_cpu_us_per_request": 4723.726977248105, + "server_cpu_percent_one_core": 776.5911980607494, + "peak_sampled_rss_mib": 11985.421875, + "mib_per_second": 1648.7854328257383 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 34.189, + "p95_ms": 240.352, + "p99_ms": 368.709, + "requests": 2660, + "response_bytes": 160182540, + "rps": 528.9619160161292, + "seconds": 5.028717417, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 60219, + "server_cpu_seconds": 42.25999999999999, + "server_cpu_us_per_request": 15887.218045112779, + "server_cpu_percent_one_core": 838.0484091428361, + "peak_sampled_rss_mib": 9909.921875, + "mib_per_second": 30.377919788909228 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.133, + "p95_ms": 3.47, + "p99_ms": 3.975, + "requests": 52205, + "response_bytes": 53931523760, + "rps": 10435.731435411833, + "seconds": 5.002524291, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 1033072, + "server_cpu_seconds": 17.909999999999997, + "server_cpu_us_per_request": 343.0705871085144, + "server_cpu_percent_one_core": 357.0921572944613, + "peak_sampled_rss_mib": 2452.625, + "mib_per_second": 10281.431146091245 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.104, + "p95_ms": 3.455, + "p99_ms": 3.686, + "requests": 52817, + "response_bytes": 55391670299, + "rps": 10558.842980758067, + "seconds": 5.002157916, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "body", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 17.240000000000002, + "server_cpu_us_per_request": 326.410057367893, + "server_cpu_percent_one_core": 343.6987719469226, + "peak_sampled_rss_mib": 2453.125, + "mib_per_second": 10560.56489900692 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.081, + "p95_ms": 3.471, + "p99_ms": 5.065, + "requests": 52403, + "response_bytes": 54957489041, + "rps": 10474.818861576781, + "seconds": 5.002759541, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 17.440000000000005, + "server_cpu_us_per_request": 332.80537373814485, + "server_cpu_percent_one_core": 347.6143858480727, + "peak_sampled_rss_mib": 2453.234375, + "mib_per_second": 10476.527077314438 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.867, + "p95_ms": 3.813, + "p99_ms": 6.352, + "requests": 57601, + "response_bytes": 60408875947, + "rps": 11513.930186034208, + "seconds": 5.002722708, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 20.870000000000005, + "server_cpu_us_per_request": 362.3200986093992, + "server_cpu_percent_one_core": 415.96100022272634, + "peak_sampled_rss_mib": 4064.53125, + "mib_per_second": 11515.80785828859 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.181, + "p95_ms": 3.58, + "p99_ms": 4.226, + "requests": 52131, + "response_bytes": 54672229857, + "rps": 10420.343766803056, + "seconds": 5.00281, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 22.360000000000014, + "server_cpu_us_per_request": 428.91945291669094, + "server_cpu_percent_one_core": 445.66643212674256, + "peak_sampled_rss_mib": 4064.609375, + "mib_per_second": 10422.043098834423 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.15, + "p95_ms": 3.567, + "p99_ms": 4.35, + "requests": 52782, + "response_bytes": 55354964154, + "rps": 10551.489425453905, + "seconds": 5.002326958, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go", + "journal": "capped", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 1048747, + "server_cpu_seconds": 21.53, + "server_cpu_us_per_request": 407.9042097684817, + "server_cpu_percent_one_core": 429.10242540817865, + "peak_sampled_rss_mib": 4064.96875, + "mib_per_second": 10553.2101444974 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.442, + "p95_ms": 1.127, + "p99_ms": 1.685, + "requests": 309160, + "response_bytes": 18617306040, + "rps": 61815.8820280146, + "seconds": 5.001303708, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 60219, + "server_cpu_seconds": 30.889999999999986, + "server_cpu_us_per_request": 99.91590115150726, + "server_cpu_percent_one_core": 614.2642794409135, + "peak_sampled_rss_mib": 4070.078125, + "mib_per_second": 3550.0436781358826 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.112, + "p95_ms": 3.466, + "p99_ms": 3.79, + "requests": 52406, + "response_bytes": 54139171232, + "rps": 10476.536807559354, + "seconds": 5.002225541, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 1033072, + "server_cpu_seconds": 17.56, + "server_cpu_us_per_request": 335.0761363202687, + "server_cpu_percent_one_core": 350.0511263242501, + "peak_sampled_rss_mib": 2316.96875, + "mib_per_second": 10321.633179530103 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.161, + "p95_ms": 3.531, + "p99_ms": 3.825, + "requests": 51247, + "response_bytes": 53745137509, + "rps": 10244.740007895776, + "seconds": 5.002274334, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "body", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 17.479999999999997, + "server_cpu_us_per_request": 341.0931371592483, + "server_cpu_percent_one_core": 348.4010995571213, + "peak_sampled_rss_mib": 2317.21875, + "mib_per_second": 10246.410702763245 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.157, + "p95_ms": 3.473, + "p99_ms": 3.678, + "requests": 51236, + "response_bytes": 53733601292, + "rps": 10240.86201447431, + "seconds": 5.003094459, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 17.630000000000003, + "server_cpu_us_per_request": 344.0939964087751, + "server_cpu_percent_one_core": 351.37355695444234, + "peak_sampled_rss_mib": 2317.359375, + "mib_per_second": 10242.532076925172 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.162, + "p95_ms": 3.619, + "p99_ms": 4.892, + "requests": 52492, + "response_bytes": 55050827524, + "rps": 10492.78531058031, + "seconds": 5.0026755, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 20.510000000000005, + "server_cpu_us_per_request": 390.72620589804166, + "server_cpu_percent_one_core": 408.6137206692628, + "peak_sampled_rss_mib": 2764.640625, + "mib_per_second": 10494.496456256073 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.224, + "p95_ms": 3.652, + "p99_ms": 4.546, + "requests": 51300, + "response_bytes": 53800721100, + "rps": 10256.125408123717, + "seconds": 5.001888916, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 21.92, + "server_cpu_us_per_request": 427.2904483430799, + "server_cpu_percent_one_core": 436.89239714083993, + "peak_sampled_rss_mib": 3080.515625, + "mib_per_second": 10257.797959702992 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.194, + "p95_ms": 3.617, + "p99_ms": 4.517, + "requests": 51592, + "response_bytes": 54106955224, + "rps": 10313.218381254797, + "seconds": 5.002512125, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go", + "journal": "capped", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 21.310000000000002, + "server_cpu_us_per_request": 413.048534656536, + "server_cpu_percent_one_core": 424.65644812610645, + "peak_sampled_rss_mib": 3284.046875, + "mib_per_second": 10314.900243459535 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.452, + "p95_ms": 1.133, + "p99_ms": 1.687, + "requests": 303638, + "response_bytes": 18284776722, + "rps": 60708.70340829969, + "seconds": 5.001556333, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 60219, + "server_cpu_seconds": 31.900000000000006, + "server_cpu_us_per_request": 105.05931405160095, + "server_cpu_percent_one_core": 634.3578291962029, + "peak_sampled_rss_mib": 3290.796875, + "mib_per_second": 3486.459169906997 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 18.013, + "p95_ms": 110.952, + "p99_ms": 184.847, + "requests": 4410, + "response_bytes": 4555847520, + "rps": 878.4465081850897, + "seconds": 5.020226, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 1033072, + "server_cpu_seconds": 46.34, + "server_cpu_us_per_request": 10507.936507936507, + "server_cpu_percent_one_core": 920.6483503495153, + "peak_sampled_rss_mib": 9747.390625, + "mib_per_second": 865.4580031431074 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 6.543, + "p95_ms": 82.75, + "p99_ms": 183.14, + "requests": 8295, + "response_bytes": 8699356365, + "rps": 1656.7680157147267, + "seconds": 5.006735959, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "body", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 39.5, + "server_cpu_us_per_request": 4761.9047619047615, + "server_cpu_percent_one_core": 786.8497094873188, + "peak_sampled_rss_mib": 11835.609375, + "mib_per_second": 1657.0381986396528 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 9.765, + "p95_ms": 33.501, + "p99_ms": 152.377, + "requests": 10601, + "response_bytes": 11117766947, + "rps": 2117.430823968414, + "seconds": 5.006539, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 41.870000000000005, + "server_cpu_us_per_request": 3949.62739364211, + "server_cpu_percent_one_core": 834.1062465604107, + "peak_sampled_rss_mib": 9514.359375, + "mib_per_second": 2117.776131004717 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 11.333, + "p95_ms": 94.494, + "p99_ms": 152.62, + "requests": 7265, + "response_bytes": 7619146955, + "rps": 1450.4508688592516, + "seconds": 5.008787375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 38.900000000000006, + "server_cpu_us_per_request": 5354.439091534757, + "server_cpu_percent_one_core": 774.4550417148067, + "peak_sampled_rss_mib": 11863.890625, + "mib_per_second": 1450.6874059329352 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 9.866, + "p95_ms": 53.54, + "p99_ms": 90.115, + "requests": 9750, + "response_bytes": 10225283250, + "rps": 1946.3682551232723, + "seconds": 5.009329542, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 42.839999999999975, + "server_cpu_us_per_request": 4393.8461538461515, + "server_cpu_percent_one_core": 853.0630223180551, + "peak_sampled_rss_mib": 12014.421875, + "mib_per_second": 1946.685665565268 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 13.53, + "p95_ms": 123.333, + "p99_ms": 185.086, + "requests": 5618, + "response_bytes": 5891860646, + "rps": 1105.1300896695218, + "seconds": 5.083564417, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "capped", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 1048747, + "server_cpu_seconds": 38.14000000000004, + "server_cpu_us_per_request": 6788.89284442863, + "server_cpu_percent_one_core": 747.7587211607638, + "peak_sampled_rss_mib": 11626.671875, + "mib_per_second": 1105.3103124147815 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 30.44, + "p95_ms": 116.877, + "p99_ms": 175.513, + "requests": 3715, + "response_bytes": 223713585, + "rps": 738.6449555467143, + "seconds": 5.029479958, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 60219, + "server_cpu_seconds": 48.48000000000002, + "server_cpu_us_per_request": 13049.798115746975, + "server_cpu_percent_one_core": 957.7215235849696, + "peak_sampled_rss_mib": 9271.328125, + "mib_per_second": 42.41987283522376 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 12.436, + "p95_ms": 87.995, + "p99_ms": 115.45, + "requests": 6093, + "response_bytes": 6294507696, + "rps": 1212.78046276208, + "seconds": 5.023992542, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 1033072, + "server_cpu_seconds": 55.730000000000004, + "server_cpu_us_per_request": 9146.56162809782, + "server_cpu_percent_one_core": 1106.6162067287762, + "peak_sampled_rss_mib": 6500.015625, + "mib_per_second": 1194.8485739007451 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 5.462, + "p95_ms": 54.701, + "p99_ms": 137.472, + "requests": 11027, + "response_bytes": 11564533169, + "rps": 2187.98931179186, + "seconds": 5.039786959, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "body", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 40.599999999999994, + "server_cpu_us_per_request": 3681.8717692935516, + "server_cpu_percent_one_core": 802.787392514638, + "peak_sampled_rss_mib": 11295.15625, + "mib_per_second": 2188.3461253869796 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 9.615, + "p95_ms": 44.083, + "p99_ms": 118.689, + "requests": 10438, + "response_bytes": 10946821186, + "rps": 2081.2165965159957, + "seconds": 5.01533575, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 33.599999999999994, + "server_cpu_us_per_request": 3219.007472695918, + "server_cpu_percent_one_core": 668.1868026416623, + "peak_sampled_rss_mib": 10251.8125, + "mib_per_second": 2081.5559977973567 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 11.638, + "p95_ms": 120.919, + "p99_ms": 272.184, + "requests": 5858, + "response_bytes": 6143559926, + "rps": 1168.667880304786, + "seconds": 5.012544709, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 39.85000000000002, + "server_cpu_us_per_request": 6802.663024923186, + "server_cpu_percent_one_core": 792.6242977544988, + "peak_sampled_rss_mib": 11978.90625, + "mib_per_second": 1168.858464685443 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 10.47, + "p95_ms": 52.875, + "p99_ms": 84.779, + "requests": 9599, + "response_bytes": 10066922453, + "rps": 1916.1694815874732, + "seconds": 5.009473375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 41.34000000000003, + "server_cpu_us_per_request": 4306.6986144390075, + "server_cpu_percent_one_core": 823.0764705284089, + "peak_sampled_rss_mib": 12071.90625, + "mib_per_second": 1916.481967264574 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 5.566, + "p95_ms": 68.745, + "p99_ms": 128.127, + "requests": 9560, + "response_bytes": 10026021320, + "rps": 1907.2610760857765, + "seconds": 5.012423375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "capped", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 39.44, + "server_cpu_us_per_request": 4125.523012552301, + "server_cpu_percent_one_core": 784.7790277020696, + "peak_sampled_rss_mib": 11993.390625, + "mib_per_second": 1907.57210899518 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 27.9, + "p95_ms": 90.132, + "p99_ms": 118.184, + "requests": 4373, + "response_bytes": 263337687, + "rps": 869.8711485289485, + "seconds": 5.027181333, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 60219, + "server_cpu_seconds": 48.629999999999995, + "server_cpu_us_per_request": 11120.512234164187, + "server_cpu_percent_one_core": 965.2970691565556, + "peak_sampled_rss_mib": 11443.96875, + "mib_per_second": 49.95610303236461 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.089, + "p95_ms": 3.434, + "p99_ms": 3.871, + "requests": 52967, + "response_bytes": 54718724624, + "rps": 10588.009997749681, + "seconds": 5.002545333, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 1033072, + "server_cpu_seconds": 17.43, + "server_cpu_us_per_request": 329.07281892499105, + "server_cpu_percent_one_core": 347.4455542681894, + "peak_sampled_rss_mib": 2383.359375, + "mib_per_second": 10431.458153147943 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.129, + "p95_ms": 3.44, + "p99_ms": 3.647, + "requests": 51673, + "response_bytes": 54191903731, + "rps": 10329.737877085106, + "seconds": 5.002353459, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "body", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 17.299999999999997, + "server_cpu_us_per_request": 334.7976699630367, + "server_cpu_percent_one_core": 344.8663524272667, + "peak_sampled_rss_mib": 2383.484375, + "mib_per_second": 10331.422433261274 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.095, + "p95_ms": 3.477, + "p99_ms": 4.074, + "requests": 53038, + "response_bytes": 55623443386, + "rps": 10601.331432723831, + "seconds": 5.0029565, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 17.690000000000005, + "server_cpu_us_per_request": 333.53444700026404, + "server_cpu_percent_one_core": 352.5025526630543, + "peak_sampled_rss_mib": 2383.609375, + "mib_per_second": 10603.060279917545 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.172, + "p95_ms": 3.617, + "p99_ms": 5.446, + "requests": 52016, + "response_bytes": 54551623952, + "rps": 10396.507075987814, + "seconds": 5.003218833, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 20.53, + "server_cpu_us_per_request": 394.6862503844971, + "server_cpu_percent_one_core": 408.01387545158815, + "peak_sampled_rss_mib": 4101.984375, + "mib_per_second": 10398.202520771974 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.156, + "p95_ms": 3.71, + "p99_ms": 6.273, + "requests": 52257, + "response_bytes": 54804371979, + "rps": 10445.76546845104, + "seconds": 5.002697041, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 22.569999999999993, + "server_cpu_us_per_request": 431.90385976998283, + "server_cpu_percent_one_core": 449.8281393515672, + "peak_sampled_rss_mib": 4102.0625, + "mib_per_second": 10447.468946210502 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 3.202, + "p95_ms": 3.619, + "p99_ms": 4.462, + "requests": 51244, + "response_bytes": 53741991268, + "rps": 10243.3897815979, + "seconds": 5.002640834, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go", + "journal": "capped", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 1048747, + "server_cpu_seconds": 20.769999999999982, + "server_cpu_us_per_request": 405.31574428225707, + "server_cpu_percent_one_core": 413.9570938537811, + "peak_sampled_rss_mib": 4102.484375, + "mib_per_second": 10245.060256272749 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.45, + "p95_ms": 1.117, + "p99_ms": 1.625, + "requests": 306865, + "response_bytes": 18479103435, + "rps": 61355.12878486319, + "seconds": 5.001456375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 60219, + "server_cpu_seconds": 32.77000000000001, + "server_cpu_us_per_request": 106.78963061932775, + "server_cpu_percent_one_core": 651.8072115357746, + "peak_sampled_rss_mib": 4109.546875, + "mib_per_second": 3523.582935615231 + } + ] +} \ No newline at end of file diff --git a/testdata/reports/benchmark-large-json-go.txt b/testdata/reports/benchmark-large-json-go.txt new file mode 100644 index 0000000..bbc0c94 --- /dev/null +++ b/testdata/reports/benchmark-large-json-go.txt @@ -0,0 +1,155 @@ +# go test -bench 'LargeJSONResponse/.*/100KiB' -count=5 at 51ac179 (baseline) +goos: darwin +goarch: arm64 +pkg: github.com/Breaking-IT/BreakMock/pkg/breakmock +cpu: Apple M4 Pro +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=false-14 8493 140305 ns/op 730.94 MB/s 248466 B/op 33 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=false-14 7977 143409 ns/op 715.12 MB/s 248147 B/op 33 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=false-14 8332 141310 ns/op 725.74 MB/s 246474 B/op 33 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=false-14 8576 141038 ns/op 727.15 MB/s 246750 B/op 33 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=false-14 8618 141952 ns/op 722.46 MB/s 246564 B/op 33 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=false-14 95509 13068 ns/op 7848.09 MB/s 113350 B/op 27 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=false-14 89340 12972 ns/op 7906.02 MB/s 113353 B/op 27 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=false-14 95146 12853 ns/op 7979.06 MB/s 113351 B/op 27 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=false-14 93328 13142 ns/op 7803.39 MB/s 113349 B/op 27 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=false-14 91056 13118 ns/op 7817.78 MB/s 113349 B/op 27 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=false-14 34675 34369 ns/op 2983.97 MB/s 114191 B/op 38 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=false-14 33564 33182 ns/op 3090.69 MB/s 114192 B/op 38 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=false-14 34522 34913 ns/op 2937.45 MB/s 114175 B/op 38 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=false-14 32865 34671 ns/op 2957.93 MB/s 114193 B/op 38 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=false-14 35008 35785 ns/op 2865.90 MB/s 114192 B/op 38 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=false-14 87 13863600 ns/op 7.40 MB/s 780593 B/op 250 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=false-14 84 13876212 ns/op 7.39 MB/s 778540 B/op 246 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=false-14 84 13908324 ns/op 7.37 MB/s 777840 B/op 248 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=false-14 90 13936296 ns/op 7.36 MB/s 777552 B/op 247 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=false-14 82 14000941 ns/op 7.32 MB/s 781346 B/op 249 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=false-14 91 13871651 ns/op 7.39 MB/s 780570 B/op 261 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=false-14 81 13923993 ns/op 7.37 MB/s 782259 B/op 263 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=false-14 82 13768023 ns/op 7.45 MB/s 781328 B/op 263 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=false-14 79 13858392 ns/op 7.40 MB/s 783351 B/op 264 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=false-14 84 13916949 ns/op 7.37 MB/s 777551 B/op 259 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=false-14 92 13778569 ns/op 7.44 MB/s 784350 B/op 290 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=false-14 85 13608666 ns/op 7.54 MB/s 783059 B/op 289 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=false-14 91 13801801 ns/op 7.43 MB/s 785264 B/op 290 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=false-14 87 13700922 ns/op 7.49 MB/s 782513 B/op 288 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=false-14 92 13723043 ns/op 7.47 MB/s 781310 B/op 288 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=false-14 2479 498972 ns/op 12.84 MB/s 359156 B/op 38 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=false-14 2445 507200 ns/op 12.63 MB/s 360874 B/op 38 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=false-14 2443 500148 ns/op 12.81 MB/s 363864 B/op 38 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=false-14 2484 497662 ns/op 12.87 MB/s 363463 B/op 38 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=false-14 2455 494711 ns/op 12.95 MB/s 360105 B/op 38 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=true-14 6709 179162 ns/op 572.42 MB/s 721350 B/op 108 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=true-14 6183 178132 ns/op 575.73 MB/s 720425 B/op 108 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=true-14 6298 179040 ns/op 572.81 MB/s 721045 B/op 108 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=true-14 5929 179173 ns/op 572.38 MB/s 721377 B/op 108 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=true-14 6164 176447 ns/op 581.22 MB/s 720514 B/op 108 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=true-14 21944 53112 ns/op 1930.94 MB/s 611842 B/op 104 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=true-14 22244 52772 ns/op 1943.36 MB/s 611841 B/op 104 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=true-14 22227 52993 ns/op 1935.27 MB/s 611841 B/op 104 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=true-14 22140 53262 ns/op 1925.47 MB/s 611841 B/op 104 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=true-14 22136 52848 ns/op 1940.58 MB/s 611842 B/op 104 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=true-14 15032 79551 ns/op 1289.17 MB/s 612668 B/op 115 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=true-14 15170 79658 ns/op 1287.43 MB/s 612668 B/op 115 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=true-14 15099 80119 ns/op 1280.04 MB/s 612668 B/op 115 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=true-14 14738 79129 ns/op 1296.05 MB/s 612669 B/op 115 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=true-14 14968 81038 ns/op 1265.52 MB/s 612668 B/op 115 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=true-14 85 13831054 ns/op 7.41 MB/s 1270250 B/op 316 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=true-14 90 13970981 ns/op 7.34 MB/s 1270513 B/op 317 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=true-14 82 14035119 ns/op 7.31 MB/s 1270781 B/op 317 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=true-14 87 13907676 ns/op 7.37 MB/s 1271013 B/op 318 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=true-14 86 14093422 ns/op 7.28 MB/s 1270347 B/op 317 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=true-14 87 14041323 ns/op 7.30 MB/s 1270237 B/op 329 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=true-14 80 14318754 ns/op 7.16 MB/s 1271848 B/op 330 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=true-14 86 15042551 ns/op 6.82 MB/s 1276239 B/op 333 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=true-14 86 14154883 ns/op 7.25 MB/s 1272933 B/op 331 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=true-14 82 13894711 ns/op 7.38 MB/s 1271157 B/op 329 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=true-14 84 14049549 ns/op 7.30 MB/s 1271948 B/op 355 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=true-14 85 14072154 ns/op 7.29 MB/s 1271716 B/op 355 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=true-14 88 13963421 ns/op 7.34 MB/s 1272489 B/op 355 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=true-14 87 14170863 ns/op 7.24 MB/s 1273019 B/op 355 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=true-14 85 14081920 ns/op 7.28 MB/s 1272610 B/op 355 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=true-14 2280 492473 ns/op 13.01 MB/s 377026 B/op 115 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=true-14 2408 491179 ns/op 13.04 MB/s 378130 B/op 115 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=true-14 2335 489777 ns/op 13.08 MB/s 376089 B/op 115 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=true-14 2440 490469 ns/op 13.06 MB/s 377118 B/op 115 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=true-14 2361 491963 ns/op 13.02 MB/s 378595 B/op 115 allocs/op +PASS +ok github.com/Breaking-IT/BreakMock/pkg/breakmock 97.609s + +# same benchmark with the large JSON optimizations +goos: darwin +goarch: arm64 +pkg: github.com/Breaking-IT/BreakMock/pkg/breakmock +cpu: Apple M4 Pro +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=false-14 548121 1994 ns/op 51422.41 MB/s 6666 B/op 26 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=false-14 637371 1963 ns/op 52256.19 MB/s 6666 B/op 26 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=false-14 636313 1994 ns/op 51421.48 MB/s 6666 B/op 26 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=false-14 577425 1976 ns/op 51910.34 MB/s 6666 B/op 26 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=false-14 619104 1994 ns/op 51422.54 MB/s 6666 B/op 26 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=false-14 626265 1971 ns/op 52044.73 MB/s 6669 B/op 26 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=false-14 631599 1962 ns/op 52273.68 MB/s 6669 B/op 26 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=false-14 612975 1993 ns/op 51469.08 MB/s 6669 B/op 26 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=false-14 588654 2004 ns/op 51163.67 MB/s 6669 B/op 26 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=false-14 609172 2022 ns/op 50721.44 MB/s 6669 B/op 26 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=false-14 301538 3918 ns/op 26177.64 MB/s 7456 B/op 32 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=false-14 315657 4041 ns/op 25377.60 MB/s 7455 B/op 32 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=false-14 272672 4017 ns/op 25527.42 MB/s 7453 B/op 32 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=false-14 305046 3706 ns/op 27675.17 MB/s 7451 B/op 32 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=false-14 335096 3713 ns/op 27620.35 MB/s 7449 B/op 32 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=false-14 86030 14242 ns/op 7201.04 MB/s 113993 B/op 33 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=false-14 81159 14422 ns/op 7110.95 MB/s 113993 B/op 33 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=false-14 83911 14339 ns/op 7152.05 MB/s 113993 B/op 33 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=false-14 82905 14384 ns/op 7129.75 MB/s 113994 B/op 33 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=false-14 85687 14789 ns/op 6934.38 MB/s 113994 B/op 33 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=false-14 71978 16566 ns/op 6190.80 MB/s 114935 B/op 41 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=false-14 71810 16751 ns/op 6122.48 MB/s 114924 B/op 41 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=false-14 74128 15976 ns/op 6419.17 MB/s 114915 B/op 41 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=false-14 72633 15621 ns/op 6565.16 MB/s 114908 B/op 41 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=false-14 79574 15082 ns/op 6799.66 MB/s 114902 B/op 41 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=false-14 57920 20487 ns/op 5005.90 MB/s 123299 B/op 187 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=false-14 59323 20216 ns/op 5073.03 MB/s 123299 B/op 187 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=false-14 57163 20412 ns/op 5024.15 MB/s 123299 B/op 187 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=false-14 57380 20121 ns/op 5096.80 MB/s 123299 B/op 187 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=false-14 61024 21384 ns/op 4795.94 MB/s 123301 B/op 187 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=false-14 309958 3982 ns/op 1609.15 MB/s 6724 B/op 29 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=false-14 299877 3885 ns/op 1648.98 MB/s 6724 B/op 29 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=false-14 313767 3853 ns/op 1662.90 MB/s 6724 B/op 29 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=false-14 319023 3786 ns/op 1692.38 MB/s 6724 B/op 29 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=false-14 309018 3955 ns/op 1619.81 MB/s 6724 B/op 29 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=true-14 118880 8458 ns/op 12124.59 MB/s 120312 B/op 100 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=true-14 129067 8391 ns/op 12222.04 MB/s 120312 B/op 100 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=true-14 129658 8383 ns/op 12233.17 MB/s 120312 B/op 100 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=true-14 130528 8354 ns/op 12275.65 MB/s 120312 B/op 100 allocs/op +BenchmarkLargeJSONResponse/jsonBody/100KiB/journal=true-14 127036 8397 ns/op 12213.03 MB/s 120312 B/op 100 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=true-14 130642 8353 ns/op 12278.09 MB/s 120312 B/op 100 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=true-14 133161 8439 ns/op 12152.71 MB/s 120312 B/op 100 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=true-14 132578 8409 ns/op 12196.44 MB/s 120312 B/op 100 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=true-14 131175 8317 ns/op 12331.02 MB/s 120312 B/op 100 allocs/op +BenchmarkLargeJSONResponse/body/100KiB/journal=true-14 130290 8396 ns/op 12214.72 MB/s 120312 B/op 100 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=true-14 100873 10886 ns/op 9420.89 MB/s 121097 B/op 106 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=true-14 103290 11181 ns/op 9172.21 MB/s 121097 B/op 106 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=true-14 100650 10962 ns/op 9355.24 MB/s 121097 B/op 106 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=true-14 105952 11034 ns/op 9294.73 MB/s 121097 B/op 106 allocs/op +BenchmarkLargeJSONResponse/bodyFileName/100KiB/journal=true-14 98370 10990 ns/op 9331.77 MB/s 121097 B/op 106 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=true-14 62851 18514 ns/op 5539.23 MB/s 227536 B/op 107 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=true-14 60342 18567 ns/op 5523.40 MB/s 227536 B/op 107 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=true-14 62540 19051 ns/op 5383.20 MB/s 227536 B/op 107 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=true-14 57967 20770 ns/op 4937.72 MB/s 227537 B/op 107 allocs/op +BenchmarkLargeJSONResponse/templateBody/100KiB/journal=true-14 58365 19708 ns/op 5203.72 MB/s 227536 B/op 107 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=true-14 51691 22814 ns/op 4495.32 MB/s 228482 B/op 115 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=true-14 51666 21809 ns/op 4702.35 MB/s 228482 B/op 115 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=true-14 52886 21672 ns/op 4732.12 MB/s 228481 B/op 115 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=true-14 53120 21734 ns/op 4718.73 MB/s 228481 B/op 115 allocs/op +BenchmarkLargeJSONResponse/templateFile/100KiB/journal=true-14 55254 21591 ns/op 4749.83 MB/s 228481 B/op 115 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=true-14 44664 26020 ns/op 3941.42 MB/s 235971 B/op 259 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=true-14 45483 26148 ns/op 3922.09 MB/s 235971 B/op 259 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=true-14 44630 26038 ns/op 3938.70 MB/s 235971 B/op 259 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=true-14 44851 26074 ns/op 3933.25 MB/s 235971 B/op 259 allocs/op +BenchmarkLargeJSONResponse/templateHelper/100KiB/journal=true-14 44708 25952 ns/op 3951.71 MB/s 235971 B/op 259 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=true-14 136545 8262 ns/op 775.46 MB/s 20455 B/op 105 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=true-14 144361 8392 ns/op 763.49 MB/s 20455 B/op 105 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=true-14 143553 8228 ns/op 778.66 MB/s 20455 B/op 105 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=true-14 143028 8378 ns/op 764.73 MB/s 20455 B/op 105 allocs/op +BenchmarkLargeJSONResponse/jsonBodyGzip/100KiB/journal=true-14 139718 8258 ns/op 775.86 MB/s 20455 B/op 105 allocs/op +PASS +ok github.com/Breaking-IT/BreakMock/pkg/breakmock 92.042s diff --git a/testdata/reports/benchmark-large-json.json b/testdata/reports/benchmark-large-json.json new file mode 100644 index 0000000..b780b91 --- /dev/null +++ b/testdata/reports/benchmark-large-json.json @@ -0,0 +1,4068 @@ +{ + "platform": "macOS-27.0.1-arm64-arm-64bit-Mach-O", + "machine": "arm64", + "logical_cpus": 14, + "go_version": "go version go1.27.1 darwin/arm64", + "java_version": "openjdk version \"27\" 2026-09-15\nOpenJDK Runtime Environment Homebrew (build 27)\nOpenJDK 64-Bit Server VM Homebrew (build 27, mixed mode, sharing)", + "binaries": { + "java": { + "path": "wiremock.jar", + "sha256": "3a53dec6c814ff73da4abb0bc51624215ea2b913beec8d19aa6d54e4c62161d3" + }, + "go-baseline": { + "path": "breakmock-baseline", + "sha256": "f1d3f87df47b80c3aee68c7041f83cd0452c3aeb74127c09bd460656b076128f" + }, + "go-optimized": { + "path": "breakmock-release", + "sha256": "27907252cfd00980e64b1b3af9820acf71556691057c846fc1e55720248c4405" + } + }, + "driver_sha256": "d1c95028a7901028d5f58236ab80683283a72a9f7d570f0b20cd9c12d99f0224", + "source_revision": "68cd31176154240eb238d4e1a743b414cf5fdfb9", + "source_dirty": false, + "settings": { + "size": 102400, + "rounds": 3, + "duration": "5s", + "warmup": "2s", + "concurrency": 32, + "response_body_bytes": { + "jsonBody": 101172, + "body": 102718, + "bodyFileName": 102718, + "templateBody": 102718, + "templateFile": 102718, + "templateHelper": 102718, + "jsonBodyGzip": 6323 + } + }, + "notes": [ + "Unlimited-rate closed loop with persistent connections; driver and servers share the host.", + "Every response is compared byte-for-byte with the first server's response for that workload.", + "With capped journals, the newest logged event (ids, timings and client details removed) must be identical across servers.", + "Server CPU is the ps user+system delta over the measurement window divided by completed requests." + ], + "journal_differences": [ + { + "server": "go-baseline", + "workload": "jsonBodyGzip", + "differing_event_fields": "response" + }, + { + "server": "go-baseline", + "workload": "templateBody", + "differing_event_fields": "responseDefinition" + }, + { + "server": "go-baseline", + "workload": "templateFile", + "differing_event_fields": "responseDefinition" + }, + { + "server": "go-baseline", + "workload": "templateHelper", + "differing_event_fields": "responseDefinition" + }, + { + "server": "go-optimized", + "workload": "jsonBodyGzip", + "differing_event_fields": "response" + }, + { + "server": "go-optimized", + "workload": "templateBody", + "differing_event_fields": "responseDefinition" + }, + { + "server": "go-optimized", + "workload": "templateFile", + "differing_event_fields": "responseDefinition" + }, + { + "server": "go-optimized", + "workload": "templateHelper", + "differing_event_fields": "responseDefinition" + } + ], + "summary": { + "disabled/jsonBody": { + "java": { + "rps": [ + 9231.164896628996, + 4951.5485539539695, + 10518.55702057524 + ], + "cpu_us": [ + 998.1159451675077, + 1060.0008070048016, + 980.500228067508 + ], + "p99_ms": [ + 30.872, + 96.249, + 20.493 + ], + "rss": [ + 2268.21875, + 3631.03125, + 2084.3125 + ] + }, + "go-baseline": { + "rps": [ + 18370.493458672066, + 20665.952738133557, + 19986.045459330635 + ], + "cpu_us": [ + 347.1655402831739, + 336.4003134705251, + 341.15351908358764 + ], + "p99_ms": [ + 6.097, + 5.149, + 5.364 + ], + "rss": [ + 60.265625, + 70.96875, + 60.90625 + ] + }, + "go-optimized": { + "rps": [ + 57896.55873091408, + 57149.22671236327, + 57239.78622603539 + ], + "cpu_us": [ + 82.2975628455686, + 80.89346694284276, + 86.48693963379277 + ], + "p99_ms": [ + 1.038, + 1.15, + 1.014 + ], + "rss": [ + 32.515625, + 33.859375, + 32.015625 + ] + } + }, + "disabled/body": { + "java": { + "rps": [ + 25607.867054068494, + 26710.715551505844, + 26791.307785236066 + ], + "cpu_us": [ + 323.5955407051182, + 308.6262650458112, + 322.6119402985074 + ], + "p99_ms": [ + 5.892, + 5.522, + 5.062 + ], + "rss": [ + 2138.078125, + 3270.703125, + 2013.515625 + ] + }, + "go-baseline": { + "rps": [ + 32947.503939180715, + 34155.43694341063, + 34596.24064528916 + ], + "cpu_us": [ + 151.83881539021723, + 154.08843692736417, + 157.54766597120678 + ], + "p99_ms": [ + 3.042, + 2.826, + 2.746 + ], + "rss": [ + 61.046875, + 71.765625, + 61.625 + ] + }, + "go-optimized": { + "rps": [ + 54115.47178218848, + 54283.37606099857, + 54420.996142720156 + ], + "cpu_us": [ + 76.92194011763662, + 77.97938721535866, + 88.32260529641712 + ], + "p99_ms": [ + 1.463, + 1.462, + 1.086 + ], + "rss": [ + 32.796875, + 34.03125, + 32.15625 + ] + } + }, + "disabled/bodyFileName": { + "java": { + "rps": [ + 13730.100999093229, + 13096.723879870464, + 15071.098534591316 + ], + "cpu_us": [ + 663.0453777596556, + 637.2878251312736, + 642.8334549313521 + ], + "p99_ms": [ + 17.699, + 19.844, + 13.374 + ], + "rss": [ + 1962.015625, + 2359.046875, + 2022.625 + ] + }, + "go-baseline": { + "rps": [ + 26719.542622628764, + 27270.07110995362, + 27673.182724000486 + ], + "cpu_us": [ + 226.6604807087911, + 244.31018301267017, + 245.946648940782 + ], + "p99_ms": [ + 3.786, + 3.578, + 3.426 + ], + "rss": [ + 61.40625, + 72.359375, + 62.046875 + ] + }, + "go-optimized": { + "rps": [ + 54303.77883484191, + 54636.15574783026, + 54573.88855676643 + ], + "cpu_us": [ + 87.14733311488206, + 86.66151869919887, + 92.95083168461935 + ], + "p99_ms": [ + 1.357, + 1.364, + 1.13 + ], + "rss": [ + 33.03125, + 34.1875, + 32.34375 + ] + } + }, + "disabled/templateBody": { + "java": { + "rps": [ + 21090.051491152302, + 22571.594987016924, + 21994.346048116226 + ], + "cpu_us": [ + 378.8805156642495, + 382.93575218573665, + 381.1575627005552 + ], + "p99_ms": [ + 7.995, + 6.91, + 7.968 + ], + "rss": [ + 3144.90625, + 2505.5, + 2431.6875 + ] + }, + "go-baseline": { + "rps": [ + 458.3267099266802, + 361.8554762171737, + 470.5646272221065 + ], + "cpu_us": [ + 22786.17710583153, + 23737.70491803279, + 22852.320675105486 + ], + "p99_ms": [ + 225.826, + 358.529, + 233.443 + ], + "rss": [ + 61.828125, + 72.75, + 62.375 + ] + }, + "go-optimized": { + "rps": [ + 33070.56683214063, + 35286.75625671316, + 35220.83238653056 + ], + "cpu_us": [ + 154.34561810795125, + 150.44368136538273, + 150.27733463532056 + ], + "p99_ms": [ + 2.971, + 2.811, + 2.752 + ], + "rss": [ + 39.34375, + 39.296875, + 39.9375 + ] + } + }, + "disabled/templateFile": { + "java": { + "rps": [ + 14296.056663779416, + 18258.285772556297, + 17138.777911987647 + ], + "cpu_us": [ + 539.2629886021949, + 537.0244639611026, + 535.8580378705675 + ], + "p99_ms": [ + 17.498, + 10.01, + 11.152 + ], + "rss": [ + 2914.515625, + 2510.515625, + 2281.125 + ] + }, + "go-baseline": { + "rps": [ + 424.64021645479124, + 446.2204288388589, + 478.8790410865918 + ], + "cpu_us": [ + 23431.09869646183, + 23485.587583148576, + 23028.666389696722 + ], + "p99_ms": [ + 267.2, + 246.914, + 200.597 + ], + "rss": [ + 61.875, + 69.28125, + 62.46875 + ] + }, + "go-optimized": { + "rps": [ + 33314.62313370773, + 34487.80118827705, + 31933.613529218528 + ], + "cpu_us": [ + 164.8800163259428, + 158.17518713724945, + 159.6583936487265 + ], + "p99_ms": [ + 2.883, + 2.792, + 3.485 + ], + "rss": [ + 39.859375, + 40.921875, + 40.296875 + ] + } + }, + "disabled/templateHelper": { + "java": { + "rps": [ + 19151.29526250423, + 22726.63749252028, + 21529.284301454136 + ], + "cpu_us": [ + 405.81793934089734, + 391.23396618161956, + 383.6367013372957 + ], + "p99_ms": [ + 11.395, + 6.569, + 8.123 + ], + "rss": [ + 4295.203125, + 2520.390625, + 2194.09375 + ] + }, + "go-baseline": { + "rps": [ + 446.4094301520854, + 442.05122915159745, + 489.4674270159097 + ], + "cpu_us": [ + 23879.53941541185, + 23897.091722595065, + 23384.677746250505 + ], + "p99_ms": [ + 233.626, + 212.257, + 188.848 + ], + "rss": [ + 62.125, + 69.578125, + 62.734375 + ] + }, + "go-optimized": { + "rps": [ + 30235.11216114002, + 23287.10181236061, + 31415.282835771395 + ], + "cpu_us": [ + 186.02651853321427, + 167.77284552705933, + 185.469242274767 + ], + "p99_ms": [ + 3.343, + 9.124, + 3.185 + ], + "rss": [ + 40.6875, + 41.78125, + 41.21875 + ] + } + }, + "disabled/jsonBodyGzip": { + "java": { + "rps": [ + 7254.624927964097, + 8785.08546254943, + 8695.321509828562 + ], + "cpu_us": [ + 1219.2837465564737, + 1203.3582089552235, + 1170.4548066095192 + ], + "p99_ms": [ + 46.395, + 26.016, + 26.586 + ], + "rss": [ + 5486.0625, + 2342.171875, + 2160.359375 + ] + }, + "go-baseline": { + "rps": [ + 12553.235867550646, + 13590.85536839251, + 13281.185953560016 + ], + "cpu_us": [ + 717.0159903166208, + 696.1485273781151, + 717.672381353763 + ], + "p99_ms": [ + 8.657, + 7.676, + 8.037 + ], + "rss": [ + 82.875, + 86.171875, + 90.3125 + ] + }, + "go-optimized": { + "rps": [ + 92594.76872925714, + 64759.26025975476, + 103854.58934775318 + ], + "cpu_us": [ + 48.02148875252093, + 35.1301792318283, + 50.68256889210563 + ], + "p99_ms": [ + 1.165, + 2.928, + 0.937 + ], + "rss": [ + 41.109375, + 42.203125, + 41.5625 + ] + } + }, + "capped/jsonBody": { + "java": { + "rps": [ + 10314.458071431387, + 10871.882693965388, + 5749.7640172292095 + ], + "cpu_us": [ + 990.7360750416682, + 883.1479268180564, + 1230.3200917526851 + ], + "p99_ms": [ + 24.153, + 21.415, + 68.64 + ], + "rss": [ + 5656.46875, + 4390.625, + 4947.46875 + ] + }, + "go-baseline": { + "rps": [ + 28462.18986886764, + 28265.300870733903, + 20462.845071357187 + ], + "cpu_us": [ + 302.2171017506393, + 306.33396769697697, + 308.85126090652386 + ], + "p99_ms": [ + 3.559, + 3.685, + 8.087 + ], + "rss": [ + 961.8125, + 872.828125, + 965.875 + ] + }, + "go-optimized": { + "rps": [ + 55219.66457228283, + 55865.94953382856, + 52832.91033983868 + ], + "cpu_us": [ + 97.58588100678215, + 97.31184527452389, + 96.61854031449276 + ], + "p99_ms": [ + 1.465, + 1.416, + 1.726 + ], + "rss": [ + 376.734375, + 372.859375, + 392.296875 + ] + } + }, + "capped/body": { + "java": { + "rps": [ + 24612.004869252258, + 25035.39072967592, + 16853.05626294329 + ], + "cpu_us": [ + 372.1727544520993, + 369.4622591027801, + 396.97699526617384 + ], + "p99_ms": [ + 5.777, + 5.498, + 15.701 + ], + "rss": [ + 4852.609375, + 4017.046875, + 3172.875 + ] + }, + "go-baseline": { + "rps": [ + 41093.4980141464, + 37497.639689457494, + 39852.210124629695 + ], + "cpu_us": [ + 156.32602222524966, + 161.62057822947875, + 164.11455406598697 + ], + "p99_ms": [ + 2.52, + 2.969, + 2.53 + ], + "rss": [ + 1006.578125, + 920.1875, + 956.046875 + ] + }, + "go-optimized": { + "rps": [ + 52849.923269566265, + 54581.32125969714, + 51024.29120682107 + ], + "cpu_us": [ + 100.5610687167303, + 95.94109458568394, + 95.45791191695629 + ], + "p99_ms": [ + 1.436, + 1.394, + 1.826 + ], + "rss": [ + 376.9375, + 373.125, + 396.984375 + ] + } + }, + "capped/bodyFileName": { + "java": { + "rps": [ + 14653.737866254103, + 14240.886284852662, + 9840.320339471175 + ], + "cpu_us": [ + 690.6431631511448, + 707.406783468104, + 681.5227106524744 + ], + "p99_ms": [ + 12.278, + 13.849, + 19.913 + ], + "rss": [ + 4344.984375, + 3693.734375, + 2996.765625 + ] + }, + "go-baseline": { + "rps": [ + 32195.695205154796, + 33639.984924526405, + 20219.296098511993 + ], + "cpu_us": [ + 243.13296858212806, + 244.52580775540295, + 242.23848131303143 + ], + "p99_ms": [ + 3.226, + 3.141, + 10.106 + ], + "rss": [ + 1007.015625, + 998.5, + 1176.0625 + ] + }, + "go-optimized": { + "rps": [ + 52803.01903345606, + 53606.11766335727, + 52288.22680482558 + ], + "cpu_us": [ + 101.96663460883127, + 102.19762185387981, + 101.86406653283625 + ], + "p99_ms": [ + 1.51, + 1.454, + 1.574 + ], + "rss": [ + 386.125, + 373.34375, + 397.171875 + ] + } + }, + "capped/templateBody": { + "java": { + "rps": [ + 20681.371738404916, + 21518.644187071222, + 15843.954955497726 + ], + "cpu_us": [ + 444.9170976942042, + 438.5149949830913, + 473.65499142020786 + ], + "p99_ms": [ + 7.469, + 6.752, + 15.046 + ], + "rss": [ + 5817.171875, + 6561.640625, + 4438.625 + ] + }, + "go-baseline": { + "rps": [ + 633.7893462770019, + 648.0758349988798, + 268.09767169057994 + ], + "cpu_us": [ + 18796.992481203008, + 18189.33823529412, + 20066.225165562922 + ], + "p99_ms": [ + 138.057, + 147.096, + 295.941 + ], + "rss": [ + 1007.375, + 998.796875, + 950.9375 + ] + }, + "go-optimized": { + "rps": [ + 50198.93515500556, + 45740.92666038976, + 48242.91210318686 + ], + "cpu_us": [ + 112.86924452480609, + 105.21254507704079, + 111.53017241379308 + ], + "p99_ms": [ + 1.812, + 2.726, + 1.99 + ], + "rss": [ + 423.75, + 434.3125, + 433.5625 + ] + } + }, + "capped/templateFile": { + "java": { + "rps": [ + 16448.1388067127, + 16619.507958128208, + 14448.954479066282 + ], + "cpu_us": [ + 604.366217727427, + 617.3760315665374, + 611.1241752313503 + ], + "p99_ms": [ + 11.393, + 9.685, + 13.169 + ], + "rss": [ + 5828.546875, + 6445.765625, + 4181.53125 + ] + }, + "go-baseline": { + "rps": [ + 624.7563783893478, + 642.2441077877511, + 224.2651975459836 + ], + "cpu_us": [ + 18929.13886240864, + 18592.638416331585, + 18987.783595113433 + ], + "p99_ms": [ + 130.325, + 124.206, + 363.538 + ], + "rss": [ + 1007.375, + 998.796875, + 911.9375 + ] + }, + "go-optimized": { + "rps": [ + 50062.29836503849, + 51078.44017634249, + 50951.79834647396 + ], + "cpu_us": [ + 118.09812888152254, + 113.32010286881884, + 117.25832149500434 + ], + "p99_ms": [ + 1.891, + 1.908, + 1.814 + ], + "rss": [ + 439.578125, + 434.5, + 433.671875 + ] + } + }, + "capped/templateHelper": { + "java": { + "rps": [ + 13674.259890985735, + 21445.39240759473, + 18438.00616854157 + ], + "cpu_us": [ + 487.1308902038508, + 443.23860669799325, + 435.71614470373913 + ], + "p99_ms": [ + 25.527, + 6.605, + 9.477 + ], + "rss": [ + 5692.328125, + 6329.34375, + 3906.96875 + ] + }, + "go-baseline": { + "rps": [ + 621.4374323477872, + 638.5560940518548, + 508.6317336422719 + ], + "cpu_us": [ + 18619.808306709274, + 18304.455445544547, + 19100.508408290956 + ], + "p99_ms": [ + 114.304, + 125.151, + 171.683 + ], + "rss": [ + 1007.515625, + 998.921875, + 602.484375 + ] + }, + "go-optimized": { + "rps": [ + 49697.8056971633, + 50204.96461485771, + 46282.48269458051 + ], + "cpu_us": [ + 112.04267679409088, + 121.63211661389576, + 121.48704987795132 + ], + "p99_ms": [ + 2.123, + 1.868, + 2.309 + ], + "rss": [ + 440.390625, + 435.296875, + 434.4375 + ] + } + }, + "capped/jsonBodyGzip": { + "java": { + "rps": [ + 7337.082690046333, + 9010.629142565644, + 8081.621498983989 + ], + "cpu_us": [ + 1209.9915556645137, + 1237.3009183266042, + 1195.2811989909478 + ], + "p99_ms": [ + 34.573, + 24.302, + 30.894 + ], + "rss": [ + 4087.03125, + 6207.609375, + 3776.40625 + ] + }, + "go-baseline": { + "rps": [ + 14728.784793295814, + 13925.368393310315, + 14010.073438150068 + ], + "cpu_us": [ + 703.7092330451536, + 699.8750735917062, + 704.5911886854387 + ], + "p99_ms": [ + 9.002, + 10.048, + 10.008 + ], + "rss": [ + 1017.03125, + 319.46875, + 561.203125 + ] + }, + "go-optimized": { + "rps": [ + 78666.69464458196, + 80753.66394967165, + 78001.47034058059 + ], + "cpu_us": [ + 66.43302437995416, + 67.53762474531037, + 66.30460133941953 + ], + "p99_ms": [ + 1.38, + 1.297, + 1.389 + ], + "rss": [ + 440.984375, + 435.59375, + 435.203125 + ] + } + } + }, + "results": [ + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.591, + "p95_ms": 9.57, + "p99_ms": 30.872, + "requests": 46177, + "response_bytes": 4671819444, + "rps": 9231.164896628996, + "seconds": 5.002293916, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 101172, + "server_cpu_seconds": 46.09, + "server_cpu_us_per_request": 998.1159451675077, + "server_cpu_percent_one_core": 918.8150455517854, + "peak_sampled_rss_mib": 2268.21875, + "mib_per_second": 890.6702183930863 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.909, + "p95_ms": 2.825, + "p99_ms": 5.892, + "requests": 128092, + "response_bytes": 13157354056, + "rps": 25607.867054068494, + "seconds": 5.002056584, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "body", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 41.45, + "server_cpu_us_per_request": 323.5955407051182, + "server_cpu_percent_one_core": 825.5051003305844, + "peak_sampled_rss_mib": 2138.078125, + "mib_per_second": 2508.5343247030332 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.347, + "p95_ms": 5.791, + "p99_ms": 17.699, + "requests": 68668, + "response_bytes": 7053439624, + "rps": 13730.100999093229, + "seconds": 5.001274208, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 45.53000000000003, + "server_cpu_us_per_request": 663.0453777596556, + "server_cpu_percent_one_core": 897.6463867165097, + "peak_sampled_rss_mib": 1962.015625, + "mib_per_second": 1344.9940819023689 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.062, + "p95_ms": 3.62, + "p99_ms": 7.995, + "requests": 105495, + "response_bytes": 10836235410, + "rps": 21090.051491152302, + "seconds": 5.0021215, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 39.97, + "server_cpu_us_per_request": 378.8805156642495, + "server_cpu_percent_one_core": 796.523660188224, + "peak_sampled_rss_mib": 3144.90625, + "mib_per_second": 2065.9712877923794 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.408, + "p95_ms": 5.693, + "p99_ms": 17.498, + "requests": 71505, + "response_bytes": 7344850590, + "rps": 14296.056663779416, + "seconds": 5.001728916, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 38.559999999999945, + "server_cpu_us_per_request": 539.2629886021949, + "server_cpu_percent_one_core": 767.9496402346674, + "peak_sampled_rss_mib": 2914.515625, + "mib_per_second": 1400.4348262692395 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.073, + "p95_ms": 3.972, + "p99_ms": 11.395, + "requests": 95979, + "response_bytes": 9858770922, + "rps": 19151.29526250423, + "seconds": 5.01161925, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "disabled", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 38.94999999999999, + "server_cpu_us_per_request": 405.81793934089734, + "server_cpu_percent_one_core": 774.1111590397907, + "peak_sampled_rss_mib": 4295.203125, + "mib_per_second": 1876.0516612757774 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.778, + "p95_ms": 14.405, + "p99_ms": 46.395, + "requests": 36300, + "response_bytes": 229524900, + "rps": 7254.624927964097, + "seconds": 5.003704583, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 6323, + "server_cpu_seconds": 44.25999999999999, + "server_cpu_us_per_request": 1219.2837465564737, + "server_cpu_percent_one_core": 882.0982338653433, + "peak_sampled_rss_mib": 5486.0625, + "mib_per_second": 43.745988292233456 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.442, + "p95_ms": 4.083, + "p99_ms": 6.097, + "requests": 91887, + "response_bytes": 9296391564, + "rps": 18370.493458672066, + "seconds": 5.001879792, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 101172, + "server_cpu_seconds": 31.9, + "server_cpu_us_per_request": 347.1655402831739, + "server_cpu_percent_one_core": 635.7886369631268, + "peak_sampled_rss_mib": 60.265625, + "mib_per_second": 1772.4795953757955 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.855, + "p95_ms": 2.147, + "p99_ms": 3.042, + "requests": 164780, + "response_bytes": 16925872040, + "rps": 32947.503939180715, + "seconds": 5.001289333, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "body", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 25.019999999999996, + "server_cpu_us_per_request": 151.83881539021723, + "server_cpu_percent_one_core": 498.3770625844448, + "peak_sampled_rss_mib": 61.046875, + "mib_per_second": 3227.521619438901 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.017, + "p95_ms": 2.684, + "p99_ms": 3.786, + "requests": 133636, + "response_bytes": 13726822648, + "rps": 26719.542622628764, + "seconds": 5.001432917, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 30.290000000000006, + "server_cpu_us_per_request": 226.6604807087911, + "server_cpu_percent_one_core": 603.444945424413, + "peak_sampled_rss_mib": 61.40625, + "mib_per_second": 2617.433528052503 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 53.043, + "p95_ms": 160.992, + "p99_ms": 225.826, + "requests": 2315, + "response_bytes": 237792170, + "rps": 458.3267099266802, + "seconds": 5.050982083, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 52.75, + "server_cpu_us_per_request": 22786.17710583153, + "server_cpu_percent_one_core": 1042.2270728114947, + "peak_sampled_rss_mib": 61.828125, + "mib_per_second": 44.89746378922342 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 55.897, + "p95_ms": 177.342, + "p99_ms": 267.2, + "requests": 2148, + "response_bytes": 220638264, + "rps": 424.64021645479124, + "seconds": 5.058399833, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 50.33000000000001, + "server_cpu_us_per_request": 23431.09869646183, + "server_cpu_percent_one_core": 993.0287805064219, + "peak_sampled_rss_mib": 61.875, + "mib_per_second": 41.597551111033674 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 57.978, + "p95_ms": 162.676, + "p99_ms": 233.626, + "requests": 2258, + "response_bytes": 231937244, + "rps": 446.4094301520854, + "seconds": 5.058136875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-baseline", + "journal": "disabled", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 53.91999999999996, + "server_cpu_us_per_request": 23879.53941541185, + "server_cpu_percent_one_core": 1063.9882088419756, + "peak_sampled_rss_mib": 62.125, + "mib_per_second": 43.73005280147735 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.036, + "p95_ms": 6.053, + "p99_ms": 8.657, + "requests": 62788, + "response_bytes": 397008524, + "rps": 12553.235867550646, + "seconds": 5.00173825, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 6323, + "server_cpu_seconds": 45.01999999999998, + "server_cpu_us_per_request": 717.0159903166208, + "server_cpu_percent_one_core": 896.998439999978, + "peak_sampled_rss_mib": 82.875, + "mib_per_second": 75.697050467036 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.538, + "p95_ms": 0.75, + "p99_ms": 1.038, + "requests": 289559, + "response_bytes": 29295263148, + "rps": 57896.55873091408, + "seconds": 5.00131625, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 101172, + "server_cpu_seconds": 23.83, + "server_cpu_us_per_request": 82.2975628455686, + "server_cpu_percent_one_core": 474.38352598876276, + "peak_sampled_rss_mib": 32.515625, + "mib_per_second": 5586.157455371895 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.562, + "p95_ms": 0.907, + "p99_ms": 1.463, + "requests": 270664, + "response_bytes": 27802064752, + "rps": 54115.47178218848, + "seconds": 5.001601041, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "body", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 20.82, + "server_cpu_us_per_request": 76.92194011763662, + "server_cpu_percent_one_core": 414.3905408733615, + "peak_sampled_rss_mib": 32.796875, + "mib_per_second": 5301.125555537067 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.563, + "p95_ms": 0.903, + "p99_ms": 1.357, + "requests": 271609, + "response_bytes": 27899133262, + "rps": 54303.77883484191, + "seconds": 5.001659292, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 23.67, + "server_cpu_us_per_request": 87.14733311488206, + "server_cpu_percent_one_core": 471.0460650535974, + "peak_sampled_rss_mib": 33.03125, + "mib_per_second": 5319.572023732463 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.854, + "p95_ms": 2.094, + "p99_ms": 2.971, + "requests": 165408, + "response_bytes": 16990378944, + "rps": 33070.56683214063, + "seconds": 5.001668125, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 25.53, + "server_cpu_us_per_request": 154.34561810795125, + "server_cpu_percent_one_core": 508.4262616445671, + "peak_sampled_rss_mib": 39.34375, + "mib_per_second": 3239.5768011701784 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.861, + "p95_ms": 2.083, + "p99_ms": 2.883, + "requests": 166606, + "response_bytes": 17113435108, + "rps": 33314.62313370773, + "seconds": 5.000987084, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 27.470000000000027, + "server_cpu_us_per_request": 164.8800163259428, + "server_cpu_percent_one_core": 547.0810601468669, + "peak_sampled_rss_mib": 39.859375, + "mib_per_second": 3263.484438942138 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.931, + "p95_ms": 2.333, + "p99_ms": 3.343, + "requests": 151215, + "response_bytes": 15532502370, + "rps": 30235.11216114002, + "seconds": 5.001304417, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-optimized", + "journal": "disabled", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 28.129999999999995, + "server_cpu_us_per_request": 186.02651853321427, + "server_cpu_percent_one_core": 560.3371578436659, + "peak_sampled_rss_mib": 40.6875, + "mib_per_second": 2961.8170270614437 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.283, + "p95_ms": 0.693, + "p99_ms": 1.165, + "requests": 463126, + "response_bytes": 2928345698, + "rps": 92594.76872925714, + "seconds": 5.00164325, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 6323, + "server_cpu_seconds": 22.24000000000001, + "server_cpu_us_per_request": 48.02148875252093, + "server_cpu_percent_one_core": 441.83449892354787, + "peak_sampled_rss_mib": 41.109375, + "mib_per_second": 558.3541132689408 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.324, + "p95_ms": 3.588, + "p99_ms": 5.149, + "requests": 103359, + "response_bytes": 10457036748, + "rps": 20665.952738133557, + "seconds": 5.001414709, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 101172, + "server_cpu_seconds": 34.77, + "server_cpu_us_per_request": 336.4003134705251, + "server_cpu_percent_one_core": 692.9350567715093, + "peak_sampled_rss_mib": 70.96875, + "mib_per_second": 1993.9573005890354 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.834, + "p95_ms": 2.04, + "p99_ms": 2.826, + "requests": 170811, + "response_bytes": 17545364298, + "rps": 34155.43694341063, + "seconds": 5.000990041, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "body", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 26.32, + "server_cpu_us_per_request": 154.08843692736417, + "server_cpu_percent_one_core": 524.2657273292009, + "peak_sampled_rss_mib": 71.765625, + "mib_per_second": 3345.850154832127 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.01, + "p95_ms": 2.558, + "p99_ms": 3.578, + "requests": 136384, + "response_bytes": 14009091712, + "rps": 27270.07110995362, + "seconds": 5.00123375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 33.32000000000001, + "server_cpu_us_per_request": 244.31018301267017, + "server_cpu_percent_one_core": 663.8367437842332, + "peak_sampled_rss_mib": 72.359375, + "mib_per_second": 2671.363033554283 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 68.131, + "p95_ms": 213.136, + "p99_ms": 358.529, + "requests": 1830, + "response_bytes": 187973940, + "rps": 361.8554762171737, + "seconds": 5.057267667, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 43.44, + "server_cpu_us_per_request": 23737.70491803279, + "server_cpu_percent_one_core": 857.3213670778279, + "peak_sampled_rss_mib": 72.75, + "mib_per_second": 35.4471881924397 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 53.963, + "p95_ms": 171.295, + "p99_ms": 246.914, + "requests": 2255, + "response_bytes": 231629090, + "rps": 446.2204288388589, + "seconds": 5.053556167, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 52.960000000000036, + "server_cpu_us_per_request": 23485.587583148576, + "server_cpu_percent_one_core": 1045.9644960353007, + "peak_sampled_rss_mib": 69.28125, + "mib_per_second": 43.71153832385054 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 58.771, + "p95_ms": 159.552, + "p99_ms": 212.257, + "requests": 2235, + "response_bytes": 229574730, + "rps": 442.05122915159745, + "seconds": 5.055975083, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-baseline", + "journal": "disabled", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 53.40999999999997, + "server_cpu_us_per_request": 23897.091722595065, + "server_cpu_percent_one_core": 1054.3551222176843, + "peak_sampled_rss_mib": 69.578125, + "mib_per_second": 43.303125530237 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.912, + "p95_ms": 5.427, + "p99_ms": 7.676, + "requests": 67974, + "response_bytes": 429799602, + "rps": 13590.85536839251, + "seconds": 5.001451208, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 6323, + "server_cpu_seconds": 47.31999999999999, + "server_cpu_us_per_request": 696.1485273781151, + "server_cpu_percent_one_core": 943.4152308291114, + "peak_sampled_rss_mib": 86.171875, + "mib_per_second": 81.95398187098107 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.541, + "p95_ms": 0.794, + "p99_ms": 1.15, + "requests": 285808, + "response_bytes": 28915766976, + "rps": 57149.22671236327, + "seconds": 5.001082542, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 101172, + "server_cpu_seconds": 23.120000000000005, + "server_cpu_us_per_request": 80.89346694284276, + "server_cpu_percent_one_core": 460.2510494656749, + "peak_sampled_rss_mib": 33.859375, + "mib_per_second": 5514.05102247545 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.558, + "p95_ms": 0.913, + "p99_ms": 1.462, + "requests": 271482, + "response_bytes": 27886088076, + "rps": 54283.37606099857, + "seconds": 5.001199625, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "body", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 21.17, + "server_cpu_us_per_request": 77.97938721535866, + "server_cpu_percent_one_core": 421.34566600323177, + "peak_sampled_rss_mib": 34.03125, + "mib_per_second": 5317.573377832079 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.559, + "p95_ms": 0.891, + "p99_ms": 1.364, + "requests": 273247, + "response_bytes": 28067385346, + "rps": 54636.15574783026, + "seconds": 5.001212041, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 23.679999999999993, + "server_cpu_us_per_request": 86.66151869919887, + "server_cpu_percent_one_core": 471.371446211439, + "peak_sampled_rss_mib": 34.1875, + "mib_per_second": 5352.131506066921 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.808, + "p95_ms": 1.988, + "p99_ms": 2.811, + "requests": 176478, + "response_bytes": 18127467204, + "rps": 35286.75625671316, + "seconds": 5.001253125, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 26.55000000000001, + "server_cpu_us_per_request": 150.44368136538273, + "server_cpu_percent_one_core": 528.84605855387, + "peak_sampled_rss_mib": 39.296875, + "mib_per_second": 3456.673649956763 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.832, + "p95_ms": 2.014, + "p99_ms": 2.792, + "requests": 172467, + "response_bytes": 17715465306, + "rps": 34487.80118827705, + "seconds": 5.000811709, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 27.28, + "server_cpu_us_per_request": 158.17518713724945, + "server_cpu_percent_one_core": 543.3021622852244, + "peak_sampled_rss_mib": 40.921875, + "mib_per_second": 3378.4083962034633 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.944, + "p95_ms": 3.506, + "p99_ms": 9.124, + "requests": 116467, + "response_bytes": 11963257306, + "rps": 23287.10181236061, + "seconds": 5.001352291, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-optimized", + "journal": "disabled", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 19.54000000000002, + "server_cpu_us_per_request": 167.77284552705933, + "server_cpu_percent_one_core": 388.81776489121705, + "peak_sampled_rss_mib": 41.78125, + "mib_per_second": 2281.1932792301727 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.332, + "p95_ms": 1.436, + "p99_ms": 2.928, + "requests": 323938, + "response_bytes": 2048259974, + "rps": 64759.26025975476, + "seconds": 5.002188084, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 6323, + "server_cpu_seconds": 11.379999999999995, + "server_cpu_us_per_request": 35.1301792318283, + "server_cpu_percent_one_core": 225.45849747809237, + "peak_sampled_rss_mib": 42.203125, + "mib_per_second": 390.5036951278966 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.742, + "p95_ms": 24.917, + "p99_ms": 96.249, + "requests": 24783, + "response_bytes": 2507345676, + "rps": 4951.5485539539695, + "seconds": 5.005100875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 101172, + "server_cpu_seconds": 26.269999999999996, + "server_cpu_us_per_request": 1060.0008070048016, + "server_cpu_percent_one_core": 523.0728054642391, + "peak_sampled_rss_mib": 3631.03125, + "mib_per_second": 477.75084524214844 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.895, + "p95_ms": 2.739, + "p99_ms": 5.522, + "requests": 133592, + "response_bytes": 13722303056, + "rps": 26710.715551505844, + "seconds": 5.001438458, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "body", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 41.23000000000001, + "server_cpu_us_per_request": 308.6262650458112, + "server_cpu_percent_one_core": 821.4937950975228, + "peak_sampled_rss_mib": 3270.703125, + "mib_per_second": 2616.568832416131 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.388, + "p95_ms": 5.737, + "p99_ms": 19.844, + "requests": 65512, + "response_bytes": 6729261616, + "rps": 13096.723879870464, + "seconds": 5.002167, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 41.75, + "server_cpu_us_per_request": 637.2878251312736, + "server_cpu_percent_one_core": 832.3672778931334, + "peak_sampled_rss_mib": 2359.046875, + "mib_per_second": 1282.9487643170685 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.039, + "p95_ms": 3.237, + "p99_ms": 6.91, + "requests": 112891, + "response_bytes": 11595937738, + "rps": 22571.594987016924, + "seconds": 5.001463125, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 43.22999999999999, + "server_cpu_us_per_request": 382.93575218573665, + "server_cpu_percent_one_core": 861.4527399620226, + "peak_sampled_rss_mib": 2505.5, + "mib_per_second": 2211.102575184254 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.244, + "p95_ms": 3.991, + "p99_ms": 10.01, + "requests": 91318, + "response_bytes": 9380002324, + "rps": 18258.285772556297, + "seconds": 5.001455292, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 49.039999999999964, + "server_cpu_us_per_request": 537.0244639611026, + "server_cpu_percent_one_core": 977.3922079144508, + "peak_sampled_rss_mib": 2510.515625, + "mib_per_second": 1788.5728816847206 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.052, + "p95_ms": 3.201, + "p99_ms": 6.569, + "requests": 113666, + "response_bytes": 11675544188, + "rps": 22726.63749252028, + "seconds": 5.001443792, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "disabled", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 44.46999999999997, + "server_cpu_us_per_request": 391.23396618161956, + "server_cpu_percent_one_core": 886.1927796988083, + "peak_sampled_rss_mib": 2520.390625, + "mib_per_second": 2226.290464359949 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.636, + "p95_ms": 11.231, + "p99_ms": 26.016, + "requests": 43952, + "response_bytes": 277908496, + "rps": 8785.08546254943, + "seconds": 5.00302475, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 6323, + "server_cpu_seconds": 52.889999999999986, + "server_cpu_us_per_request": 1203.3582089552235, + "server_cpu_percent_one_core": 1054.2953201338412, + "peak_sampled_rss_mib": 2342.171875, + "mib_per_second": 52.97479188890462 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.546, + "p95_ms": 0.744, + "p99_ms": 1.014, + "requests": 286286, + "response_bytes": 28964127192, + "rps": 57239.78622603539, + "seconds": 5.001521125, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 101172, + "server_cpu_seconds": 24.759999999999998, + "server_cpu_us_per_request": 86.48693963379277, + "server_cpu_percent_one_core": 492.87375907506566, + "peak_sampled_rss_mib": 32.015625, + "mib_per_second": 5522.788669643833 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.574, + "p95_ms": 0.777, + "p99_ms": 1.086, + "requests": 272184, + "response_bytes": 27958196112, + "rps": 54420.996142720156, + "seconds": 5.001452, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "body", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 24.04, + "server_cpu_us_per_request": 88.32260529641712, + "server_cpu_percent_one_core": 478.63284619041906, + "peak_sampled_rss_mib": 32.15625, + "mib_per_second": 5331.0545747641845 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.568, + "p95_ms": 0.811, + "p99_ms": 1.13, + "requests": 272940, + "response_bytes": 28035850920, + "rps": 54573.88855676643, + "seconds": 5.001292875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 25.370000000000005, + "server_cpu_us_per_request": 92.95083168461935, + "server_cpu_percent_one_core": 505.03962157298247, + "peak_sampled_rss_mib": 32.34375, + "mib_per_second": 5346.0318420161575 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.81, + "p95_ms": 1.958, + "p99_ms": 2.752, + "requests": 176141, + "response_bytes": 18092851238, + "rps": 35220.83238653056, + "seconds": 5.001045917, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 26.47, + "server_cpu_us_per_request": 150.27733463532056, + "server_cpu_percent_one_core": 527.1739990384403, + "peak_sampled_rss_mib": 39.9375, + "mib_per_second": 3450.2157793804604 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.867, + "p95_ms": 2.239, + "p99_ms": 3.485, + "requests": 159716, + "response_bytes": 16405708088, + "rps": 31933.613529218528, + "seconds": 5.001501, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 25.5, + "server_cpu_us_per_request": 159.6583936487265, + "server_cpu_percent_one_core": 507.8689607187557, + "peak_sampled_rss_mib": 40.296875, + "mib_per_second": 3128.201403135556 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.898, + "p95_ms": 2.219, + "p99_ms": 3.185, + "requests": 157115, + "response_bytes": 16138538570, + "rps": 31415.282835771395, + "seconds": 5.00122825, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-optimized", + "journal": "disabled", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 29.140000000000015, + "server_cpu_us_per_request": 185.469242274767, + "server_cpu_percent_one_core": 580.4447390179404, + "peak_sampled_rss_mib": 41.21875, + "mib_per_second": 3077.4259780166303 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.274, + "p95_ms": 0.608, + "p99_ms": 0.937, + "requests": 519508, + "response_bytes": 3284849084, + "rps": 103854.58934775318, + "seconds": 5.002263292, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 6323, + "server_cpu_seconds": 26.330000000000013, + "server_cpu_us_per_request": 50.68256889210563, + "server_cpu_percent_one_core": 522.6183666482791, + "peak_sampled_rss_mib": 41.5625, + "mib_per_second": 626.2517628153261 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.499, + "p95_ms": 8.601, + "p99_ms": 20.493, + "requests": 52616, + "response_bytes": 5323265952, + "rps": 10518.55702057524, + "seconds": 5.002207042, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 101172, + "server_cpu_seconds": 51.59, + "server_cpu_us_per_request": 980.500228067508, + "server_cpu_percent_one_core": 1028.4941199899, + "peak_sampled_rss_mib": 2084.3125, + "mib_per_second": 1014.8844250542049 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.942, + "p95_ms": 2.697, + "p99_ms": 5.062, + "requests": 134000, + "response_bytes": 13764212000, + "rps": 26791.307785236066, + "seconds": 5.001622208, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "body", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 43.22999999999999, + "server_cpu_us_per_request": 322.6119402985074, + "server_cpu_percent_one_core": 861.281475414768, + "peak_sampled_rss_mib": 2013.515625, + "mib_per_second": 2624.463608821753 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.542, + "p95_ms": 4.648, + "p99_ms": 13.374, + "requests": 75385, + "response_bytes": 7743396430, + "rps": 15071.098534591316, + "seconds": 5.001957875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 48.45999999999998, + "server_cpu_us_per_request": 642.8334549313521, + "server_cpu_percent_one_core": 965.870034210356, + "peak_sampled_rss_mib": 2022.625, + "mib_per_second": 1476.3575546990878 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.034, + "p95_ms": 3.437, + "p99_ms": 7.968, + "requests": 110007, + "response_bytes": 11299699026, + "rps": 21994.346048116226, + "seconds": 5.001603583, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 41.92999999999998, + "server_cpu_us_per_request": 381.1575627005552, + "server_cpu_percent_one_core": 834.8658329830859, + "peak_sampled_rss_mib": 2431.6875, + "mib_per_second": 2154.5555471138023 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.365, + "p95_ms": 4.283, + "p99_ms": 11.152, + "requests": 85713, + "response_bytes": 8804267934, + "rps": 17138.777911987647, + "seconds": 5.001115041, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 45.92999999999995, + "server_cpu_us_per_request": 535.8580378705675, + "server_cpu_percent_one_core": 915.3734231153163, + "peak_sampled_rss_mib": 2281.125, + "mib_per_second": 1678.9064307818862 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.02, + "p95_ms": 3.608, + "p99_ms": 8.123, + "requests": 107680, + "response_bytes": 11060674240, + "rps": 21529.284301454136, + "seconds": 5.001559666, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "disabled", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 41.31, + "server_cpu_us_per_request": 383.6367013372957, + "server_cpu_percent_one_core": 823.0814746803704, + "peak_sampled_rss_mib": 2194.09375, + "mib_per_second": 2108.998322369352 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.703, + "p95_ms": 10.902, + "p99_ms": 26.586, + "requests": 43513, + "response_bytes": 275132699, + "rps": 8695.321509828562, + "seconds": 5.004185291, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 6323, + "server_cpu_seconds": 50.93000000000001, + "server_cpu_us_per_request": 1170.4548066095192, + "server_cpu_percent_one_core": 1014.994485832318, + "peak_sampled_rss_mib": 2160.359375, + "mib_per_second": 52.43350783028221 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.364, + "p95_ms": 3.718, + "p99_ms": 5.364, + "requests": 99955, + "response_bytes": 10112647260, + "rps": 19986.045459330635, + "seconds": 5.0012395, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 101172, + "server_cpu_seconds": 34.1, + "server_cpu_us_per_request": 341.15351908358764, + "server_cpu_percent_one_core": 679.563566322455, + "peak_sampled_rss_mib": 60.90625, + "mib_per_second": 1928.356353007697 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.826, + "p95_ms": 1.997, + "p99_ms": 2.746, + "requests": 173027, + "response_bytes": 17772987386, + "rps": 34596.24064528916, + "seconds": 5.00132375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "body", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 27.259999999999998, + "server_cpu_us_per_request": 157.54766597120678, + "server_cpu_percent_one_core": 542.8510068329559, + "peak_sampled_rss_mib": 61.625, + "mib_per_second": 3389.0310731914633 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.991, + "p95_ms": 2.469, + "p99_ms": 3.426, + "requests": 138404, + "response_bytes": 14216582072, + "rps": 27673.182724000486, + "seconds": 5.001376292, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 34.03999999999999, + "server_cpu_us_per_request": 245.946648940782, + "server_cpu_percent_one_core": 678.1847219544007, + "peak_sampled_rss_mib": 62.046875, + "mib_per_second": 2710.851653140909 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 51.85, + "p95_ms": 163.3, + "p99_ms": 233.443, + "requests": 2370, + "response_bytes": 243441660, + "rps": 470.5646272221065, + "seconds": 5.036502667, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 54.16, + "server_cpu_us_per_request": 22852.320675105486, + "server_cpu_percent_one_core": 1073.088049860813, + "peak_sampled_rss_mib": 62.375, + "mib_per_second": 46.09628427410158 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 52.809, + "p95_ms": 146.774, + "p99_ms": 200.597, + "requests": 2407, + "response_bytes": 247242226, + "rps": 478.8790410865918, + "seconds": 5.026321458, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 55.43000000000001, + "server_cpu_us_per_request": 23028.666389696722, + "server_cpu_percent_one_core": 1100.5776511185582, + "peak_sampled_rss_mib": 62.46875, + "mib_per_second": 46.91076025231603 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 52.035, + "p95_ms": 140.084, + "p99_ms": 188.848, + "requests": 2467, + "response_bytes": 253405306, + "rps": 489.4674270159097, + "seconds": 5.040171958, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-baseline", + "journal": "disabled", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 57.69, + "server_cpu_us_per_request": 23384.677746250505, + "server_cpu_percent_one_core": 1142.2745166208488, + "peak_sampled_rss_mib": 62.734375, + "mib_per_second": 47.947993438930716 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.948, + "p95_ms": 5.641, + "p99_ms": 8.037, + "requests": 66437, + "response_bytes": 420081151, + "rps": 13281.185953560016, + "seconds": 5.002339417, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "disabled", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 6323, + "server_cpu_seconds": 47.67999999999995, + "server_cpu_us_per_request": 717.672381353763, + "server_cpu_percent_one_core": 950.4803887611993, + "peak_sampled_rss_mib": 90.3125, + "mib_per_second": 80.086649689064 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.459, + "p95_ms": 8.821, + "p99_ms": 24.153, + "requests": 51598, + "response_bytes": 5220272856, + "rps": 10314.458071431387, + "seconds": 5.002492583, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 101172, + "server_cpu_seconds": 51.11999999999999, + "server_cpu_us_per_request": 990.7360750416682, + "server_cpu_percent_one_core": 1018.9390461840279, + "peak_sampled_rss_mib": 5656.46875, + "mib_per_second": 995.191909792763 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.976, + "p95_ms": 2.975, + "p99_ms": 5.777, + "requests": 123088, + "response_bytes": 12643353184, + "rps": 24612.004869252258, + "seconds": 5.001136667, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "body", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 45.81, + "server_cpu_us_per_request": 372.1727544520993, + "server_cpu_percent_one_core": 912.7094644246703, + "peak_sampled_rss_mib": 4852.609375, + "mib_per_second": 2410.9801446531806 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.535, + "p95_ms": 4.813, + "p99_ms": 12.278, + "requests": 73294, + "response_bytes": 7528613092, + "rps": 14653.737866254103, + "seconds": 5.00172725, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 50.620000000000005, + "server_cpu_us_per_request": 690.6431631511448, + "server_cpu_percent_one_core": 1009.1021699550109, + "peak_sampled_rss_mib": 4344.984375, + "mib_per_second": 1435.4731046160591 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.138, + "p95_ms": 3.76, + "p99_ms": 7.469, + "requests": 103435, + "response_bytes": 10624636330, + "rps": 20681.371738404916, + "seconds": 5.001360708, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 46.02000000000001, + "server_cpu_us_per_request": 444.9170976942042, + "server_cpu_percent_one_core": 916.9406197843606, + "peak_sampled_rss_mib": 5817.171875, + "mib_per_second": 2025.9372160200844 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.377, + "p95_ms": 4.797, + "p99_ms": 11.393, + "requests": 82268, + "response_bytes": 8450404424, + "rps": 16448.1388067127, + "seconds": 5.001660125, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 49.71999999999997, + "server_cpu_us_per_request": 604.366217727427, + "server_cpu_percent_one_core": 990.8166783842455, + "peak_sampled_rss_mib": 5828.546875, + "mib_per_second": 1611.251756618419 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.183, + "p95_ms": 5.94, + "p99_ms": 25.527, + "requests": 69119, + "response_bytes": 7099765442, + "rps": 13674.259890985735, + "seconds": 5.054679416, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "capped", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 33.66999999999996, + "server_cpu_us_per_request": 487.1308902038508, + "server_cpu_percent_one_core": 663.8355023029104, + "peak_sampled_rss_mib": 5692.328125, + "mib_per_second": 1339.5239138434151 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.961, + "p95_ms": 13.345, + "p99_ms": 34.573, + "requests": 36711, + "response_bytes": 232123653, + "rps": 7337.082690046333, + "seconds": 5.003487292, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 6323, + "server_cpu_seconds": 44.41999999999996, + "server_cpu_us_per_request": 1209.9915556645137, + "server_cpu_percent_one_core": 884.170907449157, + "peak_sampled_rss_mib": 4087.03125, + "mib_per_second": 44.243215417063674 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.959, + "p95_ms": 2.547, + "p99_ms": 3.559, + "requests": 142348, + "response_bytes": 14401631856, + "rps": 28462.18986886764, + "seconds": 5.00130175, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 101172, + "server_cpu_seconds": 43.02, + "server_cpu_us_per_request": 302.2171017506393, + "server_cpu_percent_one_core": 856.9827384893505, + "peak_sampled_rss_mib": 961.8125, + "mib_per_second": 2746.1783155565995 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.661, + "p95_ms": 1.775, + "p99_ms": 2.52, + "requests": 205532, + "response_bytes": 21111835976, + "rps": 41093.4980141464, + "seconds": 5.001569833, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "body", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 32.13000000000001, + "server_cpu_us_per_request": 156.32602222524966, + "server_cpu_percent_one_core": 639.6742101134292, + "peak_sampled_rss_mib": 1006.578125, + "mib_per_second": 4025.4992761774915 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.842, + "p95_ms": 2.143, + "p99_ms": 3.226, + "requests": 161023, + "response_bytes": 16539960514, + "rps": 32195.695205154796, + "seconds": 5.001382917, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 39.150000000000006, + "server_cpu_us_per_request": 243.13296858212806, + "server_cpu_percent_one_core": 779.8120891805486, + "peak_sampled_rss_mib": 1007.015625, + "mib_per_second": 3153.874797900286 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 45.812, + "p95_ms": 92.955, + "p99_ms": 138.057, + "requests": 3192, + "response_bytes": 327875856, + "rps": 633.7893462770019, + "seconds": 5.036373708, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 60.0, + "server_cpu_us_per_request": 18796.992481203008, + "server_cpu_percent_one_core": 1188.8869093440487, + "peak_sampled_rss_mib": 1007.375, + "mib_per_second": 62.08569914901836 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 46.453, + "p95_ms": 92.695, + "p99_ms": 130.325, + "requests": 3147, + "response_bytes": 323253546, + "rps": 624.7563783893478, + "seconds": 5.037163459, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 59.56999999999999, + "server_cpu_us_per_request": 18929.13886240864, + "server_cpu_percent_one_core": 1180.2810249847798, + "peak_sampled_rss_mib": 1007.375, + "mib_per_second": 61.20083396472647 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 47.365, + "p95_ms": 93.254, + "p99_ms": 114.304, + "requests": 3130, + "response_bytes": 321507340, + "rps": 621.4374323477872, + "seconds": 5.036709791, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-baseline", + "journal": "capped", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 58.28000000000003, + "server_cpu_us_per_request": 18619.808306709274, + "server_cpu_percent_one_core": 1154.7969230618414, + "peak_sampled_rss_mib": 1007.515625, + "mib_per_second": 60.87571160879136 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.652, + "p95_ms": 5.445, + "p99_ms": 9.002, + "requests": 73681, + "response_bytes": 465884963, + "rps": 14728.784793295814, + "seconds": 5.00251725, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 6323, + "server_cpu_seconds": 51.849999999999966, + "server_cpu_us_per_request": 703.7092330451536, + "server_cpu_percent_one_core": 1033.2928124012285, + "peak_sampled_rss_mib": 1017.03125, + "mib_per_second": 88.81579041291182 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.542, + "p95_ms": 0.97, + "p99_ms": 1.465, + "requests": 276167, + "response_bytes": 27940367724, + "rps": 55219.66457228283, + "seconds": 5.001243708, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "jsonBody", + "round": 1, + "response_body_bytes": 101172, + "server_cpu_seconds": 26.950000000000003, + "server_cpu_us_per_request": 97.58588100678215, + "server_cpu_percent_one_core": 536.2589704105915, + "peak_sampled_rss_mib": 376.734375, + "mib_per_second": 5327.876953227042 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.575, + "p95_ms": 0.964, + "p99_ms": 1.436, + "requests": 264317, + "response_bytes": 27150113606, + "rps": 52849.923269566265, + "seconds": 5.001275, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "body", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 26.580000000000005, + "server_cpu_us_per_request": 100.5610687167303, + "server_cpu_percent_one_core": 529.0783464663973, + "peak_sampled_rss_mib": 376.9375, + "mib_per_second": 5177.153032687481 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.568, + "p95_ms": 1.014, + "p99_ms": 1.51, + "requests": 264106, + "response_bytes": 27128440108, + "rps": 52803.01903345606, + "seconds": 5.001721584, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "bodyFileName", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 26.929999999999993, + "server_cpu_us_per_request": 101.96663460883127, + "server_cpu_percent_one_core": 535.8654296311232, + "peak_sampled_rss_mib": 386.125, + "mib_per_second": 5172.558316305675 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.574, + "p95_ms": 1.22, + "p99_ms": 1.812, + "requests": 251087, + "response_bytes": 25791154466, + "rps": 50198.93515500556, + "seconds": 5.001839167, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "templateBody", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 28.33999999999999, + "server_cpu_us_per_request": 112.86924452480609, + "server_cpu_percent_one_core": 563.9112845871348, + "peak_sampled_rss_mib": 423.75, + "mib_per_second": 4917.463513614522 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.569, + "p95_ms": 1.263, + "p99_ms": 1.891, + "requests": 250385, + "response_bytes": 25719046430, + "rps": 50062.29836503849, + "seconds": 5.001468334, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "templateFile", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 29.57000000000002, + "server_cpu_us_per_request": 118.09812888152254, + "server_cpu_percent_one_core": 588.3757340144334, + "peak_sampled_rss_mib": 439.578125, + "mib_per_second": 4904.0786394691695 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.551, + "p95_ms": 1.329, + "p99_ms": 2.123, + "requests": 248566, + "response_bytes": 25532202388, + "rps": 49697.8056971633, + "seconds": 5.001548791, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-optimized", + "journal": "capped", + "workload": "templateHelper", + "round": 1, + "response_body_bytes": 102718, + "server_cpu_seconds": 27.849999999999994, + "server_cpu_us_per_request": 112.04267679409088, + "server_cpu_percent_one_core": 554.1749684167406, + "peak_sampled_rss_mib": 440.390625, + "mib_per_second": 4868.373113251895 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.333, + "p95_ms": 0.935, + "p99_ms": 1.38, + "requests": 393479, + "response_bytes": 2487967717, + "rps": 78666.69464458196, + "seconds": 5.001849916, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 1, + "response_body_bytes": 6323, + "server_cpu_seconds": 26.139999999999986, + "server_cpu_us_per_request": 66.43302437995416, + "server_cpu_percent_one_core": 519.3827471931302, + "peak_sampled_rss_mib": 440.984375, + "mib_per_second": 474.36667464989836 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.957, + "p95_ms": 2.596, + "p99_ms": 3.685, + "requests": 141349, + "response_bytes": 14300561028, + "rps": 28265.300870733903, + "seconds": 5.000795875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 101172, + "server_cpu_seconds": 43.3, + "server_cpu_us_per_request": 306.33396769697697, + "server_cpu_percent_one_core": 862.5342726061876, + "peak_sampled_rss_mib": 872.828125, + "mib_per_second": 2727.1814534129053 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.708, + "p95_ms": 1.979, + "p99_ms": 2.969, + "requests": 187538, + "response_bytes": 19263528284, + "rps": 37497.639689457494, + "seconds": 5.001328125, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "body", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 30.309999999999988, + "server_cpu_us_per_request": 161.62057822947875, + "server_cpu_percent_one_core": 603.1564674064434, + "peak_sampled_rss_mib": 920.1875, + "mib_per_second": 3673.250726339049 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.814, + "p95_ms": 2.065, + "p99_ms": 3.141, + "requests": 168244, + "response_bytes": 17281687192, + "rps": 33639.984924526405, + "seconds": 5.001310208, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 41.140000000000015, + "server_cpu_us_per_request": 244.52580775540295, + "server_cpu_percent_one_core": 819.3462778050746, + "peak_sampled_rss_mib": 998.5, + "mib_per_second": 3295.3567232871087 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 43.915, + "p95_ms": 94.74, + "p99_ms": 147.096, + "requests": 3264, + "response_bytes": 335271552, + "rps": 648.0758349988798, + "seconds": 5.036447625, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 59.370000000000005, + "server_cpu_us_per_request": 18189.33823529412, + "server_cpu_percent_one_core": 1176.4246152719838, + "peak_sampled_rss_mib": 998.796875, + "mib_per_second": 63.48519670430654 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 46.022, + "p95_ms": 90.383, + "p99_ms": 124.206, + "requests": 3233, + "response_bytes": 332087294, + "rps": 642.2441077877511, + "seconds": 5.0339115, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 60.110000000000014, + "server_cpu_us_per_request": 18592.638416331585, + "server_cpu_percent_one_core": 1191.7914495780237, + "peak_sampled_rss_mib": 998.796875, + "mib_per_second": 62.91392351507398 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 45.451, + "p95_ms": 93.323, + "p99_ms": 125.151, + "requests": 3232, + "response_bytes": 331984576, + "rps": 638.5560940518548, + "seconds": 5.061419083, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-baseline", + "journal": "capped", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 59.15999999999997, + "server_cpu_us_per_request": 18304.455445544547, + "server_cpu_percent_one_core": 1166.546546696027, + "peak_sampled_rss_mib": 998.921875, + "mib_per_second": 62.552647465532694 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.735, + "p95_ms": 5.648, + "p99_ms": 10.048, + "requests": 69641, + "response_bytes": 440340043, + "rps": 13925.368393310315, + "seconds": 5.001016708, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 6323, + "server_cpu_seconds": 48.74000000000001, + "server_cpu_us_per_request": 699.8750735917062, + "server_cpu_percent_one_core": 962.8886263187575, + "peak_sampled_rss_mib": 319.46875, + "mib_per_second": 83.97112307634461 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.539, + "p95_ms": 0.941, + "p99_ms": 1.416, + "requests": 279411, + "response_bytes": 28268569692, + "rps": 55865.94953382856, + "seconds": 5.001454416, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 101172, + "server_cpu_seconds": 27.189999999999998, + "server_cpu_us_per_request": 97.31184527452389, + "server_cpu_percent_one_core": 541.089991357449, + "peak_sampled_rss_mib": 372.859375, + "mib_per_second": 5390.233846889976 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.561, + "p95_ms": 0.924, + "p99_ms": 1.394, + "requests": 272980, + "response_bytes": 28039959640, + "rps": 54581.32125969714, + "seconds": 5.001344667, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "body", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 26.190000000000005, + "server_cpu_us_per_request": 95.94109458568394, + "server_cpu_percent_one_core": 521.295245776642, + "peak_sampled_rss_mib": 373.125, + "mib_per_second": 5346.759946015903 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.563, + "p95_ms": 0.971, + "p99_ms": 1.454, + "requests": 268108, + "response_bytes": 27539517544, + "rps": 53606.11766335727, + "seconds": 5.001444083, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 27.400000000000006, + "server_cpu_us_per_request": 102.19762185387981, + "server_cpu_percent_one_core": 545.4148200400746, + "peak_sampled_rss_mib": 373.34375, + "mib_per_second": 5251.229471344692 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.577, + "p95_ms": 1.486, + "p99_ms": 2.726, + "requests": 228775, + "response_bytes": 23499310450, + "rps": 45740.92666038976, + "seconds": 5.001538375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 24.070000000000007, + "server_cpu_us_per_request": 105.21254507704079, + "server_cpu_percent_one_core": 479.0958682355858, + "peak_sampled_rss_mib": 434.3125, + "mib_per_second": 4480.759148313442 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.553, + "p95_ms": 1.232, + "p99_ms": 1.908, + "requests": 255471, + "response_bytes": 26241470178, + "rps": 51078.44017634249, + "seconds": 5.001542708, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 28.950000000000017, + "server_cpu_us_per_request": 113.32010286881884, + "server_cpu_percent_one_core": 576.1323539813574, + "peak_sampled_rss_mib": 434.5, + "mib_per_second": 5003.619401963757 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.566, + "p95_ms": 1.265, + "p99_ms": 1.868, + "requests": 251085, + "response_bytes": 25790949030, + "rps": 50204.96461485771, + "seconds": 5.001198625, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-optimized", + "journal": "capped", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 30.54000000000002, + "server_cpu_us_per_request": 121.63211661389576, + "server_cpu_percent_one_core": 607.8670566524356, + "peak_sampled_rss_mib": 435.296875, + "mib_per_second": 4918.0541565980475 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.33, + "p95_ms": 0.9, + "p99_ms": 1.297, + "requests": 403923, + "response_bytes": 2554005129, + "rps": 80753.66394967165, + "seconds": 5.001915458, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 6323, + "server_cpu_seconds": 27.28, + "server_cpu_us_per_request": 67.53762474531037, + "server_cpu_percent_one_core": 542.1587737319248, + "peak_sampled_rss_mib": 435.59375, + "mib_per_second": 486.95127215745345 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.302, + "p95_ms": 7.935, + "p99_ms": 21.415, + "requests": 54385, + "response_bytes": 5502239220, + "rps": 10871.882693965388, + "seconds": 5.002353459, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBody", + "round": 2, + "response_body_bytes": 101172, + "server_cpu_seconds": 48.029999999999994, + "server_cpu_us_per_request": 883.1479268180564, + "server_cpu_percent_one_core": 957.3490580180169, + "peak_sampled_rss_mib": 4390.625, + "mib_per_second": 1048.9751013888038 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.965, + "p95_ms": 2.95, + "p99_ms": 5.498, + "requests": 125209, + "response_bytes": 12861218062, + "rps": 25035.39072967592, + "seconds": 5.001280042, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "body", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 46.25999999999999, + "server_cpu_us_per_request": 369.4622591027801, + "server_cpu_percent_one_core": 921.641213141419, + "peak_sampled_rss_mib": 4017.046875, + "mib_per_second": 2452.4548196514615 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.582, + "p95_ms": 5.015, + "p99_ms": 13.849, + "requests": 71232, + "response_bytes": 7316808576, + "rps": 14240.886284852662, + "seconds": 5.001935875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "bodyFileName", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 50.389999999999986, + "server_cpu_us_per_request": 707.406783468104, + "server_cpu_percent_one_core": 1004.3122663407491, + "peak_sampled_rss_mib": 3693.734375, + "mib_per_second": 1395.0303625178296 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.12, + "p95_ms": 3.55, + "p99_ms": 6.752, + "requests": 107636, + "response_bytes": 11056154648, + "rps": 21518.644187071222, + "seconds": 5.001988, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateBody", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 47.20000000000002, + "server_cpu_us_per_request": 438.5149949830913, + "server_cpu_percent_one_core": 940.1741025085098, + "peak_sampled_rss_mib": 6561.640625, + "mib_per_second": 2107.956021888334 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.436, + "p95_ms": 4.827, + "p99_ms": 9.685, + "requests": 83126, + "response_bytes": 8538536468, + "rps": 16619.507958128208, + "seconds": 5.001712458, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateFile", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 51.31999999999999, + "server_cpu_us_per_request": 617.3760315665374, + "server_cpu_percent_one_core": 1022.8313073934718, + "peak_sampled_rss_mib": 6445.765625, + "mib_per_second": 1628.0389961652882 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.123, + "p95_ms": 3.593, + "p99_ms": 6.605, + "requests": 107256, + "response_bytes": 11017121808, + "rps": 21445.39240759473, + "seconds": 5.001354042, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "capped", + "workload": "templateHelper", + "round": 2, + "response_body_bytes": 102718, + "server_cpu_seconds": 47.539999999999964, + "server_cpu_us_per_request": 443.23860669799325, + "server_cpu_percent_one_core": 947.139683957996, + "peak_sampled_rss_mib": 6329.34375, + "mib_per_second": 2100.7803128464843 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.701, + "p95_ms": 11.701, + "p99_ms": 24.302, + "requests": 45082, + "response_bytes": 285053486, + "rps": 9010.629142565644, + "seconds": 5.00320225, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 2, + "response_body_bytes": 6323, + "server_cpu_seconds": 55.77999999999997, + "server_cpu_us_per_request": 1237.3009183266042, + "server_cpu_percent_one_core": 1112.0507326185354, + "peak_sampled_rss_mib": 6207.609375, + "mib_per_second": 54.33483893245941 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.543, + "p95_ms": 1.051, + "p99_ms": 1.726, + "requests": 264235, + "response_bytes": 26733183420, + "rps": 52832.91033983868, + "seconds": 5.001333417, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 101172, + "server_cpu_seconds": 25.529999999999998, + "server_cpu_us_per_request": 96.61854031449276, + "server_cpu_percent_one_core": 508.05764984667553, + "peak_sampled_rss_mib": 392.296875, + "mib_per_second": 5097.590641882094 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.571, + "p95_ms": 1.119, + "p99_ms": 1.826, + "requests": 255191, + "response_bytes": 26212709138, + "rps": 51024.29120682107, + "seconds": 5.001362958, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "body", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 24.359999999999992, + "server_cpu_us_per_request": 95.45791191695629, + "server_cpu_percent_one_core": 484.84388495032556, + "peak_sampled_rss_mib": 396.984375, + "mib_per_second": 4998.314994985816 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.565, + "p95_ms": 1.041, + "p99_ms": 1.574, + "requests": 261525, + "response_bytes": 26863324950, + "rps": 52288.22680482558, + "seconds": 5.001603917, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 26.64, + "server_cpu_us_per_request": 101.86406653283625, + "server_cpu_percent_one_core": 530.1881078198129, + "peak_sampled_rss_mib": 397.171875, + "mib_per_second": 5122.12951749618 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.569, + "p95_ms": 1.232, + "p99_ms": 1.99, + "requests": 241280, + "response_bytes": 24783799040, + "rps": 48242.91210318686, + "seconds": 5.001356458, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 26.909999999999997, + "server_cpu_us_per_request": 111.53017241379308, + "server_cpu_percent_one_core": 535.5468873263466, + "peak_sampled_rss_mib": 433.5625, + "mib_per_second": 4725.852437415265 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.56, + "p95_ms": 1.212, + "p99_ms": 1.814, + "requests": 254822, + "response_bytes": 26174806196, + "rps": 50951.79834647396, + "seconds": 5.001236625, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 29.879999999999995, + "server_cpu_us_per_request": 117.25832149500434, + "server_cpu_percent_one_core": 594.7968710493169, + "peak_sampled_rss_mib": 433.671875, + "mib_per_second": 4991.21362929641 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.588, + "p95_ms": 1.462, + "p99_ms": 2.309, + "requests": 231465, + "response_bytes": 23775621870, + "rps": 46282.48269458051, + "seconds": 5.001136208, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-optimized", + "journal": "capped", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 28.120000000000005, + "server_cpu_us_per_request": 121.48704987795132, + "server_cpu_percent_one_core": 559.6970318450424, + "peak_sampled_rss_mib": 434.4375, + "mib_per_second": 4533.809716627045 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.34, + "p95_ms": 0.943, + "p99_ms": 1.389, + "requests": 390169, + "response_bytes": 2467038587, + "rps": 78001.47034058059, + "seconds": 5.002072375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-optimized", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 6323, + "server_cpu_seconds": 25.869999999999976, + "server_cpu_us_per_request": 66.30460133941953, + "server_cpu_percent_one_core": 513.3591236318555, + "peak_sampled_rss_mib": 435.203125, + "mib_per_second": 470.3553170809661 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.934, + "p95_ms": 18.149, + "p99_ms": 68.64, + "requests": 28773, + "response_bytes": 2911021956, + "rps": 5749.7640172292095, + "seconds": 5.004205375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 101172, + "server_cpu_seconds": 35.400000000000006, + "server_cpu_us_per_request": 1230.3200917526851, + "server_cpu_percent_one_core": 705.5592296119315, + "peak_sampled_rss_mib": 4947.46875, + "mib_per_second": 554.7667743216643 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.02, + "p95_ms": 5.051, + "p99_ms": 15.701, + "requests": 84287, + "response_bytes": 8657792066, + "rps": 16853.05626294329, + "seconds": 5.001288709, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "body", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 33.459999999999994, + "server_cpu_us_per_request": 396.97699526617384, + "server_cpu_percent_one_core": 653.5303996391017, + "peak_sampled_rss_mib": 3172.875, + "mib_per_second": 1650.9172756357275 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 2.195, + "p95_ms": 8.986, + "p99_ms": 19.913, + "requests": 49228, + "response_bytes": 5056601704, + "rps": 9840.320339471175, + "seconds": 5.002682667, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 33.55000000000001, + "server_cpu_us_per_request": 681.5227106524744, + "server_cpu_percent_one_core": 668.7280911300809, + "peak_sampled_rss_mib": 2996.765625, + "mib_per_second": 963.9530416772843 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.228, + "p95_ms": 5.088, + "p99_ms": 15.046, + "requests": 79256, + "response_bytes": 8141017808, + "rps": 15843.954955497726, + "seconds": 5.002286375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 37.53999999999999, + "server_cpu_us_per_request": 473.65499142020786, + "server_cpu_percent_one_core": 747.319366329394, + "peak_sampled_rss_mib": 4438.625, + "mib_per_second": 1552.066197508636 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.581, + "p95_ms": 5.68, + "p99_ms": 13.169, + "requests": 72293, + "response_bytes": 7425792374, + "rps": 14448.954479066282, + "seconds": 5.003337792, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 44.18000000000001, + "server_cpu_us_per_request": 611.1241752313503, + "server_cpu_percent_one_core": 875.6248960167534, + "peak_sampled_rss_mib": 4181.53125, + "mib_per_second": 1415.41262262414 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.115, + "p95_ms": 4.491, + "p99_ms": 9.477, + "requests": 92216, + "response_bytes": 9472243088, + "rps": 18438.00616854157, + "seconds": 5.001408458, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "java", + "journal": "capped", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 40.18000000000001, + "server_cpu_us_per_request": 435.71614470373913, + "server_cpu_percent_one_core": 800.6585007670336, + "peak_sampled_rss_mib": 3906.96875, + "mib_per_second": 1806.1782051279577 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.721, + "p95_ms": 13.142, + "p99_ms": 30.894, + "requests": 40434, + "response_bytes": 255664182, + "rps": 8081.621498983989, + "seconds": 5.003203875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "java", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 6323, + "server_cpu_seconds": 48.329999999999984, + "server_cpu_us_per_request": 1195.2811989909478, + "server_cpu_percent_one_core": 962.6757645138919, + "peak_sampled_rss_mib": 3776.40625, + "mib_per_second": 48.73284601028038 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.169, + "p95_ms": 3.759, + "p99_ms": 8.087, + "requests": 102347, + "response_bytes": 10354650684, + "rps": 20462.845071357187, + "seconds": 5.001601666, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "jsonBody", + "round": 3, + "response_body_bytes": 101172, + "server_cpu_seconds": 31.609999999999996, + "server_cpu_us_per_request": 308.85126090652386, + "server_cpu_percent_one_core": 629.8042141811293, + "peak_sampled_rss_mib": 965.875, + "mib_per_second": 1974.3604293435567 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.688, + "p95_ms": 1.815, + "p99_ms": 2.53, + "requests": 199312, + "response_bytes": 20472930016, + "rps": 39852.210124629695, + "seconds": 5.001278458, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "body", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 32.709999999999994, + "server_cpu_us_per_request": 164.11455406598697, + "server_cpu_percent_one_core": 651.2229991810786, + "peak_sampled_rss_mib": 956.046875, + "mib_per_second": 3903.903312284196 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.106, + "p95_ms": 3.971, + "p99_ms": 10.106, + "requests": 101140, + "response_bytes": 10388898520, + "rps": 20219.296098511993, + "seconds": 5.002152375, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "bodyFileName", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 24.5, + "server_cpu_us_per_request": 242.23848131303143, + "server_cpu_percent_one_core": 487.91888766914747, + "peak_sampled_rss_mib": 1176.0625, + "mib_per_second": 1980.6725088567305 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 106.563, + "p95_ms": 237.62, + "p99_ms": 295.941, + "requests": 1359, + "response_bytes": 139593762, + "rps": 268.09767169057994, + "seconds": 5.069048125, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "templateBody", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 27.27000000000001, + "server_cpu_us_per_request": 20066.225165562922, + "server_cpu_percent_one_core": 536.0563589438389, + "peak_sampled_rss_mib": 950.9375, + "mib_per_second": 26.262718811715118 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 130.426, + "p95_ms": 278.316, + "p99_ms": 363.538, + "requests": 1146, + "response_bytes": 117714828, + "rps": 224.2651975459836, + "seconds": 5.110021584, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "templateFile", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 21.75999999999999, + "server_cpu_us_per_request": 18987.783595113433, + "server_cpu_percent_one_core": 423.77181013509954, + "peak_sampled_rss_mib": 911.9375, + "mib_per_second": 21.968910752800316 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 55.64, + "p95_ms": 121.804, + "p99_ms": 171.683, + "requests": 2557, + "response_bytes": 262649926, + "rps": 508.6317336422719, + "seconds": 5.027212875, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders", + "server": "go-baseline", + "journal": "capped", + "workload": "templateHelper", + "round": 3, + "response_body_bytes": 102718, + "server_cpu_seconds": 48.839999999999975, + "server_cpu_us_per_request": 19100.508408290956, + "server_cpu_percent_one_core": 969.3183325359763, + "peak_sampled_rss_mib": 602.484375, + "mib_per_second": 49.82531968714417 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.726, + "p95_ms": 5.775, + "p99_ms": 10.008, + "requests": 70069, + "response_bytes": 443046287, + "rps": 14010.073438150068, + "seconds": 5.001329958, + "target_rps": 0, + "url": "http://127.0.0.1:18200/orders?customer=C-1001", + "server": "go-baseline", + "journal": "capped", + "workload": "jsonBodyGzip", + "round": 3, + "response_body_bytes": 6323, + "server_cpu_seconds": 49.370000000000005, + "server_cpu_us_per_request": 704.5911886854387, + "server_cpu_percent_one_core": 984.1396765365571, + "peak_sampled_rss_mib": 561.203125, + "mib_per_second": 84.48190150205888 + } + ] +} \ No newline at end of file diff --git a/testdata/reports/benchmark-small-ab.txt b/testdata/reports/benchmark-small-ab.txt new file mode 100644 index 0000000..ce275a8 --- /dev/null +++ b/testdata/reports/benchmark-small-ab.txt @@ -0,0 +1,67 @@ +# BenchmarkSmallResponse, 51ac179 (before) vs this branch, builds alternated 4x, -count=2 each +# before +BenchmarkSmallResponse/static/journal=false-14 558534 2005 ns/op 6684 B/op 28 allocs/op +BenchmarkSmallResponse/static/journal=false-14 604314 1994 ns/op 6684 B/op 28 allocs/op +BenchmarkSmallResponse/template/journal=false-14 496615 2456 ns/op 7541 B/op 37 allocs/op +BenchmarkSmallResponse/template/journal=false-14 461074 2447 ns/op 7542 B/op 37 allocs/op +BenchmarkSmallResponse/static/journal=true-14 192037 6067 ns/op 13964 B/op 105 allocs/op +BenchmarkSmallResponse/static/journal=true-14 196273 6037 ns/op 13964 B/op 105 allocs/op +BenchmarkSmallResponse/template/journal=true-14 186000 6705 ns/op 14805 B/op 114 allocs/op +BenchmarkSmallResponse/template/journal=true-14 179688 6724 ns/op 14805 B/op 114 allocs/op +BenchmarkSmallResponse/static/journal=false-14 607096 1968 ns/op 6684 B/op 28 allocs/op +BenchmarkSmallResponse/static/journal=false-14 626442 2004 ns/op 6684 B/op 28 allocs/op +BenchmarkSmallResponse/template/journal=false-14 454290 2524 ns/op 7542 B/op 37 allocs/op +BenchmarkSmallResponse/template/journal=false-14 474024 2515 ns/op 7542 B/op 37 allocs/op +BenchmarkSmallResponse/static/journal=true-14 192718 6090 ns/op 13964 B/op 105 allocs/op +BenchmarkSmallResponse/static/journal=true-14 200990 6179 ns/op 13964 B/op 105 allocs/op +BenchmarkSmallResponse/template/journal=true-14 171218 6796 ns/op 14805 B/op 114 allocs/op +BenchmarkSmallResponse/template/journal=true-14 175615 6771 ns/op 14805 B/op 114 allocs/op +BenchmarkSmallResponse/static/journal=false-14 561589 2006 ns/op 6684 B/op 28 allocs/op +BenchmarkSmallResponse/static/journal=false-14 584196 2021 ns/op 6684 B/op 28 allocs/op +BenchmarkSmallResponse/template/journal=false-14 480321 2513 ns/op 7542 B/op 37 allocs/op +BenchmarkSmallResponse/template/journal=false-14 473484 2529 ns/op 7542 B/op 37 allocs/op +BenchmarkSmallResponse/static/journal=true-14 195763 6241 ns/op 13964 B/op 105 allocs/op +BenchmarkSmallResponse/static/journal=true-14 195920 6105 ns/op 13964 B/op 105 allocs/op +BenchmarkSmallResponse/template/journal=true-14 177855 6853 ns/op 14805 B/op 114 allocs/op +BenchmarkSmallResponse/template/journal=true-14 172764 6893 ns/op 14805 B/op 114 allocs/op +BenchmarkSmallResponse/static/journal=false-14 500782 2013 ns/op 6684 B/op 28 allocs/op +BenchmarkSmallResponse/static/journal=false-14 582896 2059 ns/op 6684 B/op 28 allocs/op +BenchmarkSmallResponse/template/journal=false-14 477272 2538 ns/op 7542 B/op 37 allocs/op +BenchmarkSmallResponse/template/journal=false-14 494641 2551 ns/op 7542 B/op 37 allocs/op +BenchmarkSmallResponse/static/journal=true-14 191170 6287 ns/op 13964 B/op 105 allocs/op +BenchmarkSmallResponse/static/journal=true-14 191486 6324 ns/op 13964 B/op 105 allocs/op +BenchmarkSmallResponse/template/journal=true-14 173762 6792 ns/op 14805 B/op 114 allocs/op +BenchmarkSmallResponse/template/journal=true-14 186760 6757 ns/op 14805 B/op 114 allocs/op +# after +BenchmarkSmallResponse/static/journal=false-14 552046 1988 ns/op 6660 B/op 27 allocs/op +BenchmarkSmallResponse/static/journal=false-14 595610 1995 ns/op 6660 B/op 27 allocs/op +BenchmarkSmallResponse/template/journal=false-14 493066 2424 ns/op 7429 B/op 34 allocs/op +BenchmarkSmallResponse/template/journal=false-14 500925 2474 ns/op 7429 B/op 34 allocs/op +BenchmarkSmallResponse/static/journal=true-14 200967 6124 ns/op 13908 B/op 102 allocs/op +BenchmarkSmallResponse/static/journal=true-14 185034 6017 ns/op 13908 B/op 102 allocs/op +BenchmarkSmallResponse/template/journal=true-14 178166 6592 ns/op 14677 B/op 109 allocs/op +BenchmarkSmallResponse/template/journal=true-14 190866 6559 ns/op 14677 B/op 109 allocs/op +BenchmarkSmallResponse/static/journal=false-14 597766 2053 ns/op 6660 B/op 27 allocs/op +BenchmarkSmallResponse/static/journal=false-14 595266 2032 ns/op 6660 B/op 27 allocs/op +BenchmarkSmallResponse/template/journal=false-14 479194 2463 ns/op 7429 B/op 34 allocs/op +BenchmarkSmallResponse/template/journal=false-14 483546 2495 ns/op 7429 B/op 34 allocs/op +BenchmarkSmallResponse/static/journal=true-14 199009 6141 ns/op 13908 B/op 102 allocs/op +BenchmarkSmallResponse/static/journal=true-14 190734 6209 ns/op 13908 B/op 102 allocs/op +BenchmarkSmallResponse/template/journal=true-14 183266 6542 ns/op 14677 B/op 109 allocs/op +BenchmarkSmallResponse/template/journal=true-14 190650 6694 ns/op 14677 B/op 109 allocs/op +BenchmarkSmallResponse/static/journal=false-14 597154 2021 ns/op 6660 B/op 27 allocs/op +BenchmarkSmallResponse/static/journal=false-14 600434 2004 ns/op 6660 B/op 27 allocs/op +BenchmarkSmallResponse/template/journal=false-14 499939 2452 ns/op 7429 B/op 34 allocs/op +BenchmarkSmallResponse/template/journal=false-14 453127 2498 ns/op 7429 B/op 34 allocs/op +BenchmarkSmallResponse/static/journal=true-14 189019 6130 ns/op 13908 B/op 102 allocs/op +BenchmarkSmallResponse/static/journal=true-14 195826 6295 ns/op 13908 B/op 102 allocs/op +BenchmarkSmallResponse/template/journal=true-14 180087 6757 ns/op 14677 B/op 109 allocs/op +BenchmarkSmallResponse/template/journal=true-14 177388 6726 ns/op 14677 B/op 109 allocs/op +BenchmarkSmallResponse/static/journal=false-14 593422 2010 ns/op 6660 B/op 27 allocs/op +BenchmarkSmallResponse/static/journal=false-14 603954 2098 ns/op 6660 B/op 27 allocs/op +BenchmarkSmallResponse/template/journal=false-14 468920 2539 ns/op 7429 B/op 34 allocs/op +BenchmarkSmallResponse/template/journal=false-14 464192 2533 ns/op 7429 B/op 34 allocs/op +BenchmarkSmallResponse/static/journal=true-14 193902 6190 ns/op 13908 B/op 102 allocs/op +BenchmarkSmallResponse/static/journal=true-14 197265 6303 ns/op 13908 B/op 102 allocs/op +BenchmarkSmallResponse/template/journal=true-14 173436 6764 ns/op 14677 B/op 109 allocs/op +BenchmarkSmallResponse/template/journal=true-14 183620 6594 ns/op 14677 B/op 109 allocs/op diff --git a/testdata/reports/java-go-2026-10-13/cpu-10k-journal.json b/testdata/reports/java-go-2026-10-13/cpu-10k-journal.json new file mode 100644 index 0000000..e2fe91a --- /dev/null +++ b/testdata/reports/java-go-2026-10-13/cpu-10k-journal.json @@ -0,0 +1,329 @@ +{ + "platform": "macOS-27.0.1-arm64-arm-64bit-Mach-O", + "machine": "arm64", + "logical_cpus": 14, + "server_revision": "68cd31176154240eb238d4e1a743b414cf5fdfb9", + "source_dirty_at_start": false, + "binary_sha256": { + "go": "27907252cfd00980e64b1b3af9820acf71556691057c846fc1e55720248c4405", + "driver": "d1c95028a7901028d5f58236ab80683283a72a9f7d570f0b20cd9c12d99f0224" + }, + "java_version": "openjdk version \"27\" 2026-09-15\nOpenJDK Runtime Environment Homebrew (build 27)\nOpenJDK 64-Bit Server VM Homebrew (build 27, mixed mode, sharing)\n", + "servers": [ + "java", + "go" + ], + "go_version": "go version go1.27.1 darwin/arm64", + "reference_jar_sha256": "3a53dec6c814ff73da4abb0bc51624215ea2b913beec8d19aa6d54e4c62161d3", + "notes": [ + "Same host and workload driver; CPU shared with client and any other host processes.", + "Request journals bounded to 1000 entries on both servers.", + "10s warmup per workload; sequential alternating server order; 32 clients.", + "Target RPS 10000 (0 means unlimited); fixed-rate arrivals dispatched in 1ms batches; drops/errors fail the run.", + "CPU is cumulative process user+system time delta from ps, all server threads, excluding load generator; 100% means one fully occupied core. CPU window includes driver launch and report serialization.", + "Fixed-rate latency includes scheduling/queue delay from each intended arrival; up to one second of arrivals can queue. Achieved RPS must be within 2% of target.", + "RSS sampled every 100ms; not an allocation or production capacity guarantee." + ], + "results": [ + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.995, + "p95_ms": 1.544, + "p99_ms": 2.247, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9999.286634226037, + "seconds": 15.001070125, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 18.529999999999998, + "cpu_measurement_wall_seconds": 15.020092125050724, + "server_cpu_percent_one_core": 123.36808486743833, + "server_cpu_us_per_request": 123.5333333333333, + "server": "java", + "round": 1, + "workload": "static", + "version": "4.0.0-beta.40", + "idle_rss_mib": 200.21875, + "peak_sampled_rss_mib": 429.515625, + "startup_seconds": 0.5066232919925824 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.978, + "p95_ms": 1.54, + "p99_ms": 2.434, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9999.413839693738, + "seconds": 15.000879292, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 19.40999999999999, + "cpu_measurement_wall_seconds": 15.02166875009425, + "server_cpu_percent_one_core": 129.21334056096933, + "server_cpu_us_per_request": 129.39999999999992, + "server": "java", + "round": 1, + "workload": "template", + "version": "4.0.0-beta.40", + "idle_rss_mib": 200.21875, + "peak_sampled_rss_mib": 476.28125, + "startup_seconds": 0.5066232919925824 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.966, + "p95_ms": 1.576, + "p99_ms": 3.107, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9998.882096984687, + "seconds": 15.001677042, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 12.739999999999998, + "cpu_measurement_wall_seconds": 15.021831042016856, + "server_cpu_percent_one_core": 84.80990076619517, + "server_cpu_us_per_request": 84.93333333333332, + "server": "go", + "round": 1, + "workload": "static", + "version": "0.1.0", + "idle_rss_mib": 20.203125, + "peak_sampled_rss_mib": 42.078125, + "startup_seconds": 0.10770912491716444 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.967, + "p95_ms": 1.525, + "p99_ms": 2.641, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9999.242446726377, + "seconds": 15.001136416, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 13.950000000000003, + "cpu_measurement_wall_seconds": 15.022451416938566, + "server_cpu_percent_one_core": 92.86100925093143, + "server_cpu_us_per_request": 93.00000000000003, + "server": "go", + "round": 1, + "workload": "template", + "version": "0.1.0", + "idle_rss_mib": 20.203125, + "peak_sampled_rss_mib": 43.046875, + "startup_seconds": 0.10770912491716444 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.912, + "p95_ms": 1.498, + "p99_ms": 6.212, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9998.891706178469, + "seconds": 15.001662625, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 12.33, + "cpu_measurement_wall_seconds": 15.019175207940862, + "server_cpu_percent_one_core": 82.09505401788606, + "server_cpu_us_per_request": 82.2, + "server": "go", + "round": 2, + "workload": "static", + "version": "0.1.0", + "idle_rss_mib": 20.21875, + "peak_sampled_rss_mib": 42.46875, + "startup_seconds": 0.10425658395979553 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.02, + "p95_ms": 1.676, + "p99_ms": 3.704, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9999.369317778515, + "seconds": 15.000946083, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 13.140000000000004, + "cpu_measurement_wall_seconds": 15.019588582916185, + "server_cpu_percent_one_core": 87.48575187303005, + "server_cpu_us_per_request": 87.60000000000002, + "server": "go", + "round": 2, + "workload": "template", + "version": "0.1.0", + "idle_rss_mib": 20.21875, + "peak_sampled_rss_mib": 43.078125, + "startup_seconds": 0.10425658395979553 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.936, + "p95_ms": 1.455, + "p99_ms": 2.266, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9999.370372978849, + "seconds": 15.0009445, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 17.1, + "cpu_measurement_wall_seconds": 15.018962583038956, + "server_cpu_percent_one_core": 113.85606632585382, + "server_cpu_us_per_request": 114.0, + "server": "java", + "round": 2, + "workload": "static", + "version": "4.0.0-beta.40", + "idle_rss_mib": 192.40625, + "peak_sampled_rss_mib": 372.21875, + "startup_seconds": 0.581430958933197 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.979, + "p95_ms": 1.478, + "p99_ms": 2.15, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9998.926448596969, + "seconds": 15.0016105, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 16.359999999999992, + "cpu_measurement_wall_seconds": 15.029314167099074, + "server_cpu_percent_one_core": 108.85393583570132, + "server_cpu_us_per_request": 109.06666666666662, + "server": "java", + "round": 2, + "workload": "template", + "version": "4.0.0-beta.40", + "idle_rss_mib": 192.40625, + "peak_sampled_rss_mib": 402.03125, + "startup_seconds": 0.581430958933197 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.988, + "p95_ms": 1.477, + "p99_ms": 1.974, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9999.330155538833, + "seconds": 15.001004834, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 19.459999999999997, + "cpu_measurement_wall_seconds": 15.024848208064213, + "server_cpu_percent_one_core": 129.51877936148017, + "server_cpu_us_per_request": 129.73333333333332, + "server": "java", + "round": 3, + "workload": "static", + "version": "4.0.0-beta.40", + "idle_rss_mib": 196.4375, + "peak_sampled_rss_mib": 426.953125, + "startup_seconds": 0.5757892499677837 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.987, + "p95_ms": 1.484, + "p99_ms": 2.113, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9999.417700575903, + "seconds": 15.0008735, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 18.64, + "cpu_measurement_wall_seconds": 15.019378666067496, + "server_cpu_percent_one_core": 124.1063323219381, + "server_cpu_us_per_request": 124.26666666666667, + "server": "java", + "round": 3, + "workload": "template", + "version": "4.0.0-beta.40", + "idle_rss_mib": 196.4375, + "peak_sampled_rss_mib": 490.359375, + "startup_seconds": 0.5757892499677837 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.923, + "p95_ms": 1.425, + "p99_ms": 2.086, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9999.317851869115, + "seconds": 15.001023292, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 13.849999999999998, + "cpu_measurement_wall_seconds": 15.019783333060332, + "server_cpu_percent_one_core": 92.21171632692263, + "server_cpu_us_per_request": 92.33333333333331, + "server": "go", + "round": 3, + "workload": "static", + "version": "0.1.0", + "idle_rss_mib": 20.15625, + "peak_sampled_rss_mib": 42.640625, + "startup_seconds": 0.10493291693273932 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.867, + "p95_ms": 1.311, + "p99_ms": 1.78, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9999.23089249052, + "seconds": 15.00115375, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 11.030000000000005, + "cpu_measurement_wall_seconds": 15.01892287505325, + "server_cpu_percent_one_core": 73.44068607157621, + "server_cpu_us_per_request": 73.53333333333337, + "server": "go", + "round": 3, + "workload": "template", + "version": "0.1.0", + "idle_rss_mib": 20.15625, + "peak_sampled_rss_mib": 43.28125, + "startup_seconds": 0.10493291693273932 + } + ] +} \ No newline at end of file diff --git a/testdata/reports/java-go-2026-10-13/cpu-10k.json b/testdata/reports/java-go-2026-10-13/cpu-10k.json new file mode 100644 index 0000000..77ff2d7 --- /dev/null +++ b/testdata/reports/java-go-2026-10-13/cpu-10k.json @@ -0,0 +1,329 @@ +{ + "platform": "macOS-27.0.1-arm64-arm-64bit-Mach-O", + "machine": "arm64", + "logical_cpus": 14, + "server_revision": "68cd31176154240eb238d4e1a743b414cf5fdfb9", + "source_dirty_at_start": false, + "binary_sha256": { + "go": "27907252cfd00980e64b1b3af9820acf71556691057c846fc1e55720248c4405", + "driver": "d1c95028a7901028d5f58236ab80683283a72a9f7d570f0b20cd9c12d99f0224" + }, + "java_version": "openjdk version \"27\" 2026-09-15\nOpenJDK Runtime Environment Homebrew (build 27)\nOpenJDK 64-Bit Server VM Homebrew (build 27, mixed mode, sharing)\n", + "servers": [ + "java", + "go" + ], + "go_version": "go version go1.27.1 darwin/arm64", + "reference_jar_sha256": "3a53dec6c814ff73da4abb0bc51624215ea2b913beec8d19aa6d54e4c62161d3", + "notes": [ + "Same host and workload driver; CPU shared with client and any other host processes.", + "Request journals disabled on both servers.", + "10s warmup per workload; sequential alternating server order; 32 clients.", + "Target RPS 10000 (0 means unlimited); fixed-rate arrivals dispatched in 1ms batches; drops/errors fail the run.", + "CPU is cumulative process user+system time delta from ps, all server threads, excluding load generator; 100% means one fully occupied core. CPU window includes driver launch and report serialization.", + "Fixed-rate latency includes scheduling/queue delay from each intended arrival; up to one second of arrivals can queue. Achieved RPS must be within 2% of target.", + "RSS sampled every 100ms; not an allocation or production capacity guarantee." + ], + "results": [ + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.846, + "p95_ms": 1.256, + "p99_ms": 1.379, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9999.465805871194, + "seconds": 15.000801334, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 10.31, + "cpu_measurement_wall_seconds": 15.01970549998805, + "server_cpu_percent_one_core": 68.64315681827586, + "server_cpu_us_per_request": 68.73333333333333, + "server": "java", + "round": 1, + "workload": "static", + "version": "4.0.0-beta.40", + "idle_rss_mib": 188.484375, + "peak_sampled_rss_mib": 378.28125, + "startup_seconds": 0.5949984589824453 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.94, + "p95_ms": 1.868, + "p99_ms": 6.153, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9999.08466712443, + "seconds": 15.001373125, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 11.030000000000001, + "cpu_measurement_wall_seconds": 15.028771125013009, + "server_cpu_percent_one_core": 73.39256089702712, + "server_cpu_us_per_request": 73.53333333333335, + "server": "java", + "round": 1, + "workload": "template", + "version": "4.0.0-beta.40", + "idle_rss_mib": 188.484375, + "peak_sampled_rss_mib": 402.875, + "startup_seconds": 0.5949984589824453 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.922, + "p95_ms": 1.447, + "p99_ms": 3.396, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9998.43057968001, + "seconds": 15.0023545, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 8.3, + "cpu_measurement_wall_seconds": 15.031740250065923, + "server_cpu_percent_one_core": 55.216494310854, + "server_cpu_us_per_request": 55.33333333333334, + "server": "go", + "round": 1, + "workload": "static", + "version": "0.1.0", + "idle_rss_mib": 20.140625, + "peak_sampled_rss_mib": 28.71875, + "startup_seconds": 0.10899241594597697 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.98, + "p95_ms": 1.517, + "p99_ms": 2.358, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9999.34512622211, + "seconds": 15.000982375, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 10.130000000000003, + "cpu_measurement_wall_seconds": 15.02341849997174, + "server_cpu_percent_one_core": 67.42806239484747, + "server_cpu_us_per_request": 67.53333333333335, + "server": "go", + "round": 1, + "workload": "template", + "version": "0.1.0", + "idle_rss_mib": 20.140625, + "peak_sampled_rss_mib": 29.15625, + "startup_seconds": 0.10899241594597697 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 1.025, + "p95_ms": 1.627, + "p99_ms": 2.984, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9998.853714745386, + "seconds": 15.001719625, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 8.219999999999999, + "cpu_measurement_wall_seconds": 15.022747665992938, + "server_cpu_percent_one_core": 54.717021032095545, + "server_cpu_us_per_request": 54.8, + "server": "go", + "round": 2, + "workload": "static", + "version": "0.1.0", + "idle_rss_mib": 18.28125, + "peak_sampled_rss_mib": 28.125, + "startup_seconds": 0.10224858298897743 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.98, + "p95_ms": 1.575, + "p99_ms": 2.907, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9998.459126132484, + "seconds": 15.002311667, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 9.25, + "cpu_measurement_wall_seconds": 15.033546666963957, + "server_cpu_percent_one_core": 61.5290603402773, + "server_cpu_us_per_request": 61.666666666666664, + "server": "go", + "round": 2, + "workload": "template", + "version": "0.1.0", + "idle_rss_mib": 18.28125, + "peak_sampled_rss_mib": 28.921875, + "startup_seconds": 0.10224858298897743 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.939, + "p95_ms": 1.513, + "p99_ms": 2.331, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9998.644655720713, + "seconds": 15.002033292, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 13.190000000000001, + "cpu_measurement_wall_seconds": 15.032114750007167, + "server_cpu_percent_one_core": 87.74547174071907, + "server_cpu_us_per_request": 87.93333333333335, + "server": "java", + "round": 2, + "workload": "static", + "version": "4.0.0-beta.40", + "idle_rss_mib": 187.515625, + "peak_sampled_rss_mib": 376.890625, + "startup_seconds": 0.596845000050962 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.983, + "p95_ms": 1.579, + "p99_ms": 2.353, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9999.169041055015, + "seconds": 15.001246542, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 14.089999999999996, + "cpu_measurement_wall_seconds": 15.025509999948554, + "server_cpu_percent_one_core": 93.77385526380294, + "server_cpu_us_per_request": 93.93333333333331, + "server": "java", + "round": 2, + "workload": "template", + "version": "4.0.0-beta.40", + "idle_rss_mib": 187.515625, + "peak_sampled_rss_mib": 380.140625, + "startup_seconds": 0.596845000050962 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.984, + "p95_ms": 1.567, + "p99_ms": 2.416, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9998.733827006374, + "seconds": 15.0018995, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 14.43, + "cpu_measurement_wall_seconds": 15.029797542025335, + "server_cpu_percent_one_core": 96.00927730165213, + "server_cpu_us_per_request": 96.2, + "server": "java", + "round": 3, + "workload": "static", + "version": "4.0.0-beta.40", + "idle_rss_mib": 199.625, + "peak_sampled_rss_mib": 259.3125, + "startup_seconds": 0.5746353330323473 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.988, + "p95_ms": 1.657, + "p99_ms": 9.897, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9999.400785907905, + "seconds": 15.000898875, + "target_rps": 10000, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 13.519999999999996, + "cpu_measurement_wall_seconds": 15.019450666964985, + "server_cpu_percent_one_core": 90.01660779602942, + "server_cpu_us_per_request": 90.13333333333331, + "server": "java", + "round": 3, + "workload": "template", + "version": "4.0.0-beta.40", + "idle_rss_mib": 199.625, + "peak_sampled_rss_mib": 281.84375, + "startup_seconds": 0.5746353330323473 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.901, + "p95_ms": 1.404, + "p99_ms": 2.088, + "requests": 150000, + "response_bytes": 2550000, + "rps": 9999.005348942914, + "seconds": 15.001492125, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 8.530000000000001, + "cpu_measurement_wall_seconds": 15.027287916978821, + "server_cpu_percent_one_core": 56.7634029981035, + "server_cpu_us_per_request": 56.86666666666668, + "server": "go", + "round": 3, + "workload": "static", + "version": "0.1.0", + "idle_rss_mib": 19.96875, + "peak_sampled_rss_mib": 28.4375, + "startup_seconds": 0.10821258299984038 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.954, + "p95_ms": 1.495, + "p99_ms": 2.231, + "requests": 150000, + "response_bytes": 1800000, + "rps": 9999.40128584801, + "seconds": 15.000898125, + "target_rps": 10000, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 10.52, + "cpu_measurement_wall_seconds": 15.02026541705709, + "server_cpu_percent_one_core": 70.03870909001006, + "server_cpu_us_per_request": 70.13333333333334, + "server": "go", + "round": 3, + "workload": "template", + "version": "0.1.0", + "idle_rss_mib": 19.96875, + "peak_sampled_rss_mib": 29.171875, + "startup_seconds": 0.10821258299984038 + } + ] +} \ No newline at end of file diff --git a/testdata/reports/java-go-2026-10-13/throughput-journal.json b/testdata/reports/java-go-2026-10-13/throughput-journal.json new file mode 100644 index 0000000..795348b --- /dev/null +++ b/testdata/reports/java-go-2026-10-13/throughput-journal.json @@ -0,0 +1,229 @@ +{ + "platform": "macOS-27.0.1-arm64-arm-64bit-Mach-O", + "machine": "arm64", + "logical_cpus": 14, + "server_revision": "68cd31176154240eb238d4e1a743b414cf5fdfb9", + "source_dirty_at_start": false, + "binary_sha256": { + "go": "27907252cfd00980e64b1b3af9820acf71556691057c846fc1e55720248c4405", + "driver": "d1c95028a7901028d5f58236ab80683283a72a9f7d570f0b20cd9c12d99f0224" + }, + "java_version": "openjdk version \"27\" 2026-09-15\nOpenJDK Runtime Environment Homebrew (build 27)\nOpenJDK 64-Bit Server VM Homebrew (build 27, mixed mode, sharing)\n", + "servers": [ + "java", + "go" + ], + "go_version": "go version go1.27.1 darwin/arm64", + "reference_jar_sha256": "3a53dec6c814ff73da4abb0bc51624215ea2b913beec8d19aa6d54e4c62161d3", + "notes": [ + "Same host and workload driver; CPU shared with client and any other host processes.", + "Request journals bounded to 1000 entries on both servers.", + "3s warmup per workload; sequential alternating server order; 32 clients.", + "Target RPS 0 (0 means unlimited); fixed-rate arrivals dispatched in 1ms batches; drops/errors fail the run.", + "CPU is cumulative process user+system time delta from ps, all server threads, excluding load generator; 100% means one fully occupied core. CPU window includes driver launch and report serialization.", + "Fixed-rate latency includes scheduling/queue delay from each intended arrival; up to one second of arrivals can queue. Achieved RPS must be within 2% of target.", + "RSS sampled every 100ms; not an allocation or production capacity guarantee." + ], + "results": [ + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.389, + "p95_ms": 1.133, + "p99_ms": 2.089, + "requests": 334226, + "response_bytes": 5681842, + "rps": 66824.48497098467, + "seconds": 5.001549958, + "target_rps": 0, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 28.430000000000003, + "cpu_measurement_wall_seconds": 5.031556957983412, + "server_cpu_percent_one_core": 565.0338501065962, + "server_cpu_us_per_request": 85.06220341924327, + "server": "java", + "round": 1, + "workload": "static", + "version": "4.0.0-beta.40", + "idle_rss_mib": 192.984375, + "peak_sampled_rss_mib": 838.796875, + "startup_seconds": 0.604199624969624 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.399, + "p95_ms": 1.157, + "p99_ms": 2.039, + "requests": 326857, + "response_bytes": 3922284, + "rps": 65344.13950970927, + "seconds": 5.002085917, + "target_rps": 0, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 26.370000000000005, + "cpu_measurement_wall_seconds": 5.030609667068347, + "server_cpu_percent_one_core": 524.1909379816276, + "server_cpu_us_per_request": 80.67748281358516, + "server": "java", + "round": 1, + "workload": "template", + "version": "4.0.0-beta.40", + "idle_rss_mib": 192.984375, + "peak_sampled_rss_mib": 870.40625, + "startup_seconds": 0.604199624969624 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.284, + "p95_ms": 0.92, + "p99_ms": 1.375, + "requests": 433837, + "response_bytes": 7375229, + "rps": 86736.49074028547, + "seconds": 5.001781791, + "target_rps": 0, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 24.71, + "cpu_measurement_wall_seconds": 5.033183332998306, + "server_cpu_percent_one_core": 490.94178306594813, + "server_cpu_us_per_request": 56.95687550854353, + "server": "go", + "round": 1, + "workload": "static", + "version": "0.1.0", + "idle_rss_mib": 20.203125, + "peak_sampled_rss_mib": 52.328125, + "startup_seconds": 0.1040184999583289 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.285, + "p95_ms": 0.917, + "p99_ms": 1.368, + "requests": 435669, + "response_bytes": 5228028, + "rps": 87106.74318217432, + "seconds": 5.001553084, + "target_rps": 0, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 25.339999999999996, + "cpu_measurement_wall_seconds": 5.0329642499564216, + "server_cpu_percent_one_core": 503.4806277477414, + "server_cpu_us_per_request": 58.16342223109746, + "server": "go", + "round": 1, + "workload": "template", + "version": "0.1.0", + "idle_rss_mib": 20.203125, + "peak_sampled_rss_mib": 53.453125, + "startup_seconds": 0.1040184999583289 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.27, + "p95_ms": 0.86, + "p99_ms": 1.256, + "requests": 462011, + "response_bytes": 7854187, + "rps": 92362.38643595521, + "seconds": 5.002155291, + "target_rps": 0, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 26.38, + "cpu_measurement_wall_seconds": 5.036390708992258, + "server_cpu_percent_one_core": 523.7877981328901, + "server_cpu_us_per_request": 57.09820761843333, + "server": "go", + "round": 2, + "workload": "static", + "version": "0.1.0", + "idle_rss_mib": 20.015625, + "peak_sampled_rss_mib": 51.734375, + "startup_seconds": 0.10590966697782278 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.28, + "p95_ms": 0.917, + "p99_ms": 1.345, + "requests": 440307, + "response_bytes": 5283684, + "rps": 88023.72144603502, + "seconds": 5.00214025, + "target_rps": 0, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 26.35, + "cpu_measurement_wall_seconds": 5.03388962498866, + "server_cpu_percent_one_core": 523.4520810547044, + "server_cpu_us_per_request": 59.84460842094266, + "server": "go", + "round": 2, + "workload": "template", + "version": "0.1.0", + "idle_rss_mib": 20.015625, + "peak_sampled_rss_mib": 52.53125, + "startup_seconds": 0.10590966697782278 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.351, + "p95_ms": 0.863, + "p99_ms": 1.383, + "requests": 399303, + "response_bytes": 6788151, + "rps": 79831.47814735626, + "seconds": 5.001823958, + "target_rps": 0, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 32.56, + "cpu_measurement_wall_seconds": 5.031631916994229, + "server_cpu_percent_one_core": 647.1061583425707, + "server_cpu_us_per_request": 81.54208708674867, + "server": "java", + "round": 2, + "workload": "static", + "version": "4.0.0-beta.40", + "idle_rss_mib": 176.0625, + "peak_sampled_rss_mib": 743.109375, + "startup_seconds": 0.6020318340742961 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.359, + "p95_ms": 0.869, + "p99_ms": 1.372, + "requests": 393778, + "response_bytes": 4725336, + "rps": 78729.93338038654, + "seconds": 5.001630042, + "target_rps": 0, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 31.61, + "cpu_measurement_wall_seconds": 5.030941042001359, + "server_cpu_percent_one_core": 628.3118751760451, + "server_cpu_us_per_request": 80.27365673044203, + "server": "java", + "round": 2, + "workload": "template", + "version": "4.0.0-beta.40", + "idle_rss_mib": 176.0625, + "peak_sampled_rss_mib": 897.375, + "startup_seconds": 0.6020318340742961 + } + ] +} \ No newline at end of file diff --git a/testdata/reports/java-go-2026-10-13/throughput.json b/testdata/reports/java-go-2026-10-13/throughput.json new file mode 100644 index 0000000..f33dcd5 --- /dev/null +++ b/testdata/reports/java-go-2026-10-13/throughput.json @@ -0,0 +1,229 @@ +{ + "platform": "macOS-27.0.1-arm64-arm-64bit-Mach-O", + "machine": "arm64", + "logical_cpus": 14, + "server_revision": "68cd31176154240eb238d4e1a743b414cf5fdfb9", + "source_dirty_at_start": false, + "binary_sha256": { + "go": "27907252cfd00980e64b1b3af9820acf71556691057c846fc1e55720248c4405", + "driver": "d1c95028a7901028d5f58236ab80683283a72a9f7d570f0b20cd9c12d99f0224" + }, + "java_version": "openjdk version \"27\" 2026-09-15\nOpenJDK Runtime Environment Homebrew (build 27)\nOpenJDK 64-Bit Server VM Homebrew (build 27, mixed mode, sharing)\n", + "servers": [ + "java", + "go" + ], + "go_version": "go version go1.27.1 darwin/arm64", + "reference_jar_sha256": "3a53dec6c814ff73da4abb0bc51624215ea2b913beec8d19aa6d54e4c62161d3", + "notes": [ + "Same host and workload driver; CPU shared with client and any other host processes.", + "Request journals disabled on both servers.", + "3s warmup per workload; sequential alternating server order; 32 clients.", + "Target RPS 0 (0 means unlimited); fixed-rate arrivals dispatched in 1ms batches; drops/errors fail the run.", + "CPU is cumulative process user+system time delta from ps, all server threads, excluding load generator; 100% means one fully occupied core. CPU window includes driver launch and report serialization.", + "Fixed-rate latency includes scheduling/queue delay from each intended arrival; up to one second of arrivals can queue. Achieved RPS must be within 2% of target.", + "RSS sampled every 100ms; not an allocation or production capacity guarantee." + ], + "results": [ + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.379, + "p95_ms": 1.291, + "p99_ms": 2.844, + "requests": 308550, + "response_bytes": 5245350, + "rps": 61681.769796008615, + "seconds": 5.002288375, + "target_rps": 0, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 22.18, + "cpu_measurement_wall_seconds": 5.03047658293508, + "server_cpu_percent_one_core": 440.9124987330498, + "server_cpu_us_per_request": 71.88462161724193, + "server": "java", + "round": 1, + "workload": "static", + "version": "4.0.0-beta.40", + "idle_rss_mib": 179.5, + "peak_sampled_rss_mib": 691.03125, + "startup_seconds": 0.7216408749809489 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.333, + "p95_ms": 0.865, + "p99_ms": 1.332, + "requests": 414251, + "response_bytes": 4971012, + "rps": 82822.16125301394, + "seconds": 5.001692708, + "target_rps": 0, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 26.210000000000008, + "cpu_measurement_wall_seconds": 5.03247370896861, + "server_cpu_percent_one_core": 520.8174253009992, + "server_cpu_us_per_request": 63.270818899652646, + "server": "java", + "round": 1, + "workload": "template", + "version": "4.0.0-beta.40", + "idle_rss_mib": 179.5, + "peak_sampled_rss_mib": 685.546875, + "startup_seconds": 0.7216408749809489 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.246, + "p95_ms": 0.604, + "p99_ms": 0.946, + "requests": 563550, + "response_bytes": 9580350, + "rps": 112668.78857385939, + "seconds": 5.001828875, + "target_rps": 0, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 21.139999999999997, + "cpu_measurement_wall_seconds": 5.037573999958113, + "server_cpu_percent_one_core": 419.64644092922055, + "server_cpu_us_per_request": 37.512199449915705, + "server": "go", + "round": 1, + "workload": "static", + "version": "0.1.0", + "idle_rss_mib": 20.046875, + "peak_sampled_rss_mib": 30.5625, + "startup_seconds": 0.5218207079451531 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.261, + "p95_ms": 0.679, + "p99_ms": 1.111, + "requests": 521013, + "response_bytes": 6252156, + "rps": 104156.27476780285, + "seconds": 5.002223833, + "target_rps": 0, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 19.140000000000008, + "cpu_measurement_wall_seconds": 5.037655499996617, + "server_cpu_percent_one_core": 379.9386440778425, + "server_cpu_us_per_request": 36.736127505455734, + "server": "go", + "round": 1, + "workload": "template", + "version": "0.1.0", + "idle_rss_mib": 20.046875, + "peak_sampled_rss_mib": 31.96875, + "startup_seconds": 0.5218207079451531 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.261, + "p95_ms": 0.663, + "p99_ms": 1.083, + "requests": 522695, + "response_bytes": 8885815, + "rps": 104489.57904135292, + "seconds": 5.002364875, + "target_rps": 0, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 19.750000000000004, + "cpu_measurement_wall_seconds": 5.038599916035309, + "server_cpu_percent_one_core": 391.9739675528864, + "server_cpu_us_per_request": 37.784941505084234, + "server": "go", + "round": 2, + "workload": "static", + "version": "0.1.0", + "idle_rss_mib": 19.953125, + "peak_sampled_rss_mib": 31.078125, + "startup_seconds": 0.10637358401436359 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.249, + "p95_ms": 0.666, + "p99_ms": 1.058, + "requests": 536981, + "response_bytes": 6443772, + "rps": 107355.9048628993, + "seconds": 5.001876708, + "target_rps": 0, + "url": "http://127.0.0.1:18102/bench?name=Ada", + "server_cpu_seconds": 20.919999999999995, + "cpu_measurement_wall_seconds": 5.038664374966174, + "server_cpu_percent_one_core": 415.1893923305903, + "server_cpu_us_per_request": 38.9585478815824, + "server": "go", + "round": 2, + "workload": "template", + "version": "0.1.0", + "idle_rss_mib": 19.953125, + "peak_sampled_rss_mib": 32.171875, + "startup_seconds": 0.10637358401436359 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.332, + "p95_ms": 0.845, + "p99_ms": 1.278, + "requests": 417540, + "response_bytes": 7098180, + "rps": 83479.18438799956, + "seconds": 5.001725916, + "target_rps": 0, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 25.580000000000002, + "cpu_measurement_wall_seconds": 5.032948625041172, + "server_cpu_percent_one_core": 508.2507672088694, + "server_cpu_us_per_request": 61.26359151219045, + "server": "java", + "round": 2, + "workload": "static", + "version": "4.0.0-beta.40", + "idle_rss_mib": 193.828125, + "peak_sampled_rss_mib": 504.40625, + "startup_seconds": 0.5796587079530582 + }, + { + "concurrency": 32, + "dropped": 0, + "errors": 0, + "p50_ms": 0.337, + "p95_ms": 0.858, + "p99_ms": 1.286, + "requests": 415905, + "response_bytes": 4990860, + "rps": 83154.73280027695, + "seconds": 5.001579417, + "target_rps": 0, + "url": "http://127.0.0.1:18101/bench?name=Ada", + "server_cpu_seconds": 24.89, + "cpu_measurement_wall_seconds": 5.03594641701784, + "server_cpu_percent_one_core": 494.24672025678996, + "server_cpu_us_per_request": 59.84539738642238, + "server": "java", + "round": 2, + "workload": "template", + "version": "4.0.0-beta.40", + "idle_rss_mib": 193.828125, + "peak_sampled_rss_mib": 515.734375, + "startup_seconds": 0.5796587079530582 + } + ] +} \ No newline at end of file