Domanda di colloquio di Synechron

when JVM trigger gc.

Risposte di colloquio

Anonimo

18 dic 2019

Minor GC is always triggered when JVM is unable to allocate space for a new Object, e.g. the Eden is getting full. So the higher the allocation rate, the more frequently Minor GC is executed. Whenever the pool is filled, its entire content is copied and the pointer can start tracking the free memory from zero again

Anonimo

24 dic 2020

There is Old and Young (Eden) GC , also there are many levels in Young. If you play around VM visualizer you can find Young does lot of work on free up. Old generally have things which won't be GC for example String Pool, metadata.