While the Shenandoah pause-less garbage collector can bound pause times to a few ms independent of heap size, one tradeoff is that it needs a much larger heap than stop-the-world collectors in order to assure pause-less operation. This is because extra memory is required to support allocation during current GC phases and to hold the floating garbage that was allocated during the preceding garbage collection pass but cannot be reclaimed until the end of the current garbage collection pass. Adding a second generation to Shenandoah allows typical young-generation garbage collection passes to complete in much less time and with much less effort than is required for traditional Shenandoah's full garbage collection cycles. This reduces the size of the working memory buffer and reduces the CPUOresources required by concurrent garbage collection worker threads. The benefits include lower capital and operational costs and reduced carbon emissions. This talk describes the motivation, design, and best-practice recommendations for making effective use of generational Shenandoah in services that have timeliness constraints.
Kelvin Nilsen has been innovating with Java since 1995 with publication of the original proposal for real-time Java as a research scientist at Iowa State University. Subsequently, he founded and led NewMonics, architecting and supporting the Perc real-time virtual machine over a span of roughly 20 years. After NewMonics was acquired by PTC, Kelvin worked four years at IBM, then joined the Amazon Corretto team in 2019. He holds 12 patents with additional patents pending for inventions related to time-critical deployment of Java.