How to limit total memory consumed by Java 8 application?

前端 未结 1 1895
星月不相逢
星月不相逢 2021-02-02 00:14

In order to limit total memory consumed by Java 7 application I could use the following formula (taken from this article):

Max memory = [-Xmx] + [-XX:MaxP

相关标签:
1条回答
  • 2021-02-02 00:54

    Yes, there is -XX:MaxMetaspaceSize instead of -XX:MaxPermSize.

    Consider also -XX:MaxDirectMemorySize to limit memory for direct ByteBuffers.

    0 讨论(0)
提交回复
热议问题