Spot allocation pressure, avoid accidental retention, and tune GC only after you can measure the benefit.
If your service gets slower over time, GC pressure is often the real problem. In Clojure, allocation can show up in places that feel “free” at first: intermediate sequences, persistent collection churn, or accidentally retaining the head of a lazy sequence.
This section helps you reason about allocation and retention in idiomatic Clojure, and connect those patterns to the JVM signals you already know (GC pauses, allocation rate, heap growth).
You will also learn a practical ordering: fix the biggest sources of churn in code first, then consider JVM tuning only when the data shows it’s necessary.