Skip to content
Sharp

Memory Management · interview question

Why is simply increasing -Xmx a weak first response to an allocation-churn problem?

Multiple choiceMediumchapter-14-curatedpremiummemory-managementout-of-memory-errors
Choose one answer
Answer and explanation

Correct answer

A. Because churn is about object creation and collection rate, not just retained heap size

Why

If the service keeps allocating and discarding too many temporary objects, a bigger heap may only delay collections. The core problem is still hot-path churn and GC overhead.

Test yourself on Memory Management

A free test with instant, explained results. No account needed.

Start free test
All Memory Management questions →