Back to projects

Java · Evidence-driven Java performance lab

Java Performance Lab

Correctness-first Java 21 case study with JMH, Java Flight Recorder, allocation and GC profiling, virtual threads, and reproducible evidence.

The challenge

Performance optimizations quickly become misleading without proven behavioral equivalence, controlled measurement conditions, and raw evidence.

The result

A multi-module lab that verifies two implementations against the same contract, measures them in forked JVMs, and diagnoses runtime effects with JFR.

What this project demonstrates

Reviewable decisions instead of slogans.

  • Contract and differential tests before every performance claim
  • JMH with forks, warm-up, parameters, and the GC profiler
  • Custom JFR events and memory-conscious streaming analysis
  • Versioned raw evidence and a deliberately bounded optimization decision

Technologies

  • Java 21
  • JMH
  • JFR
  • Virtual Threads
  • Maven
  • JUnit