要深入了解你需要理解 JVM 的原理,最好有 production 的经验。 我不建议背答案,一知半解很可能弄巧成拙。
可以看一看以下知识点:
1)JVM Heap: YoungGen, OldGen, PermGen (static variable is here)
2) GC pause: How can it affect P99 latency; Why P99 latency is critical for Internet companies.
3) How to debug the JVM HeapDump