In my five-stack comparison on a 512 MiB VPS, I measured what it took to run the same business logic with different Java stacks and a local MariaDB instance. This time I wanted to see what happens under sustained load. How much memory does each stack leave available when it shares the server with PostgreSQL, and how long do the slowest requests take?

From one comparison to an ongoing benchmark

I started Framework Benchmarks so I could repeat the comparison as the stacks change and so others could run it themselves. Each implementation has to pass the same correctness checks before it sees the same stream of requests. The runner records what happens under load and builds the report from those measurements.

What the application does

Market Replay Portfolio models an investment portfolio service. HTTP requests read and update portfolios and retrieve valuations. Database transactions persist changes, and a background job periodically ingests replayed market prices. Each implementation uses the same PostgreSQL schema and public synthetic price fixture. Reference application

The comparison covers Jex + Jdbi, Quarkus + Jdbi, Spring Boot + JDBC and Micronaut Data JDBC. I also created CoilBase, which both Jdbi implementations use. The Jex implementation uses CoilBase Core and its Jex adapter. The Quarkus implementation uses CoilBase Core for Jdbi-based database access and explicit transaction management, alongside Quarkus REST and Agroal. CoilBase's contribution to resource use was not measured separately.

How I ran the benchmark

I ran the same PostgreSQL correctness checks against each implementation before measuring. The frozen protocol defines workload phases, runtime settings, sampling and acceptance criteria. I ran each stack twice on a Debian 13 QEMU/KVM guest with one vCPU, 512 MiB RAM and no swap. The Linux host used an AMD Ryzen 7 4700U. Each application shared the guest with PostgreSQL 18.7. Frozen v1 protocol

I use GitHub Actions to build all four applications, check their behavior against PostgreSQL, and test the workload and benchmark runner on pushes and pull requests. CI also rebuilds the report from the recorded measurements and checks that it matches the accepted HTML byte for byte. I ran the performance measurements separately on the dedicated Debian VM. CI workflow

What the workload sends

I started each run with a fresh database seeded with 1,000 users. I used the same seeded request mix for every stack, with weights of 40% portfolio reads, 25% portfolio edits, 25% valuations, 8% latest quotes and 2% quote history. Meanwhile, the application polls for replayed prices every 60 seconds.

After readiness and a brief stabilization period, I sampled the guest for 30 seconds with quote polling active and no HTTP workload. The driver runs outside the VM and opens a fresh HTTP connection per request through an SSH tunnel. It offers 5 requests per second for 30 seconds, then warms up the application at 40 requests per second for 125 seconds. The measured phase keeps that rate for another 185 seconds, scheduling 7,400 requests per run. Edits and warmed caches carry forward from the earlier phases.

JVM settings and tested versions

I ran all four stacks on OpenJDK HotSpot 27 (build 27+35-2325) with G1, a 16 MiB initial heap, an 80 MiB maximum heap and UTC.

-Xms16m -Xmx80m -XX:+UseG1GC -Duser.timezone=UTC
  • Jex + Jdbi used Avaje Jex 3.6, Avaje HTTP 3.12.1, Jdbi 3.55.0, CoilBase Core and Jex adapter 0.1.0-preview5, and HikariCP 7.0.2.
  • Quarkus + Jdbi used Quarkus REST 3.40.1, Jdbi 3.55.0, CoilBase Core 0.1.0-preview5, and Agroal 3.2.1.
  • Spring Boot + JDBC used Spring Boot 4.1.1, Spring JDBC 7.0.9, Tomcat 11.0.24, and HikariCP 7.0.2.
  • Micronaut Data JDBC used Micronaut HTTP Server Netty 5.2.11, Micronaut Data JDBC 5.2.0, Micronaut JDBC Hikari 7.2.0, and HikariCP 7.1.0.

Results

Two rounds for four stacks. Jex + Jdbi had the shortest readiness time, lowest peak app RSS and most available guest memory in both rounds. Sustained p99 was 11.02 to 11.51 ms across all runs.
The generated chart shows both rounds separately. Readiness ends at the first successful database-backed readiness check. App RSS and guest MemAvailable are sampled sustained-phase extrema. Client-observed p99 includes scheduling and SSH transport.

All eight runs sustained 40 requests per second with zero workload errors, timeouts, unsent requests or OOM kills. Sustained p99 stayed between 11.02 and 11.51 ms across the suite. Detailed HTML report · Recorded evidence

Where the stacks differed

Jex + Jdbi reached readiness in 4.64–4.87 seconds and had sampled peak app RSS of 148.16–149.96 MiB. Spring Boot + JDBC took 10.64–10.82 seconds and peaked at 221.73–233.29 MiB. Quarkus + Jdbi and Micronaut Data JDBC fell between those stacks on both measures in each round, with Micronaut closer to Spring Boot on peak RSS in the second round.

The guest memory samples show what that footprint means for the whole VM. The lowest MemAvailable sample in each Jex run was 196.95–202.43 MiB across the two rounds, compared with 119.36–126.95 MiB for Spring Boot. MemAvailable estimates how much memory Linux can make available without swapping or reclaiming heavily used pages. It reflects the guest as a whole, including PostgreSQL and the OS. With similar tail latency at the tested load, the clearest differences were how quickly each stack became ready and how much memory remained available during the run.

What this comparison covers

The fixed offered load answers how these stacks behaved at 40 requests per second. Finding maximum throughput would require a separate load sweep. The measurements include the HTTP server, persistence code, connection pool and JVM, so the differences cannot be attributed to framework overhead alone. The results apply to this fixture, request mix, JVM configuration, PostgreSQL settings and guest. Two rounds show how the observations repeated in this setup.

What comes next

I plan to use the project to compare more frameworks and persistence approaches, and to see how the results change with different JVM settings, memory budgets and workloads.

Reproduce and contribute

The repository has the implementation, setup instructions, correctness checks, run commands and report generator. Try the Debian suite on your own Linux host and share your environment and results. If you propose another stack or workload, tell us what decision the comparison would inform and how the existing correctness contract would apply.