The Self-Cleaning Castle: How Garbage Collection Works in Java
Garbage collection is one of the most valuable—but often invisible—features of modern programming languages. Like living in a self-cleaning castle, it takes care of the mess so we can focus on other things. But while it feels automatic, there’s a lot happening behind the scenes.
In this talk, we’ll explore the fundamentals of garbage collection through the lens of life in a castle with my cat: what it cleans up, how it works, and why it sometimes causes trouble. We’ll walk through some core techniques, their trade-offs, and the optimizations that make them more efficient. From there, we’ll dive into modern Java garbage collectors looking at how they build on these principles to meet today’s performance demands.
By the end, you’ll have a clear understanding of how garbage collection works, why it matters, and how overlooking it can cause problems when we least expect it


