<div dir="ltr"><div dir="ltr"><div dir="ltr"><div>Re Erik:</div><div><br></div><div>> Could you elaborate the concrete scenario you have in mind? What use case do you have in mind where AHS is not enough, while external heap control is?</div><div><br></div><div>One example is a customized container environment that requires non-standard approaches to read container memory usage and container memory limit, i.e., the application cannot use standard cgroup's <span style="color:rgb(0,0,0)">memory.memsw.usage_in_bytes, </span><span style="color:rgb(0,0,0)">memory.memsw.max_usage_in_bytes control files. </span><font color="#000000">Instead, the </font>customized container could provide its own library for the application to get container usage and limit.</div><div><br></div><div>Without CurrentMaxHeapSize or a high-precedence SoftMaxHeapSize, the JVM has no way to use the container-provided library to get signals for memory pressure. With such JVM flags, the application could use the container-provided library to calculate a value for those JVM flags based on memory pressure, and pass that information to the JVM.</div><div><br></div><div><div dir="ltr" class="gmail_signature"><div dir="ltr">-Man</div></div></div></div></div>
</div>