JDK-8186248 : Allow more flexibility in selecting Heap % of available RAM
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: gc
  • Affected Version: 8u144
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2017-08-15
  • Updated: 2019-02-19
  • Resolved: 2017-08-31
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 10
10 b23Fixed
Related Reports
CSR :  
Duplicate :  
Relates :  
Description
A customer has asked if it would be possible to specify an option that would allow the VM to select a percentage of available RAM.  This becomes important when running the JVM in a Docker container where the amount of RAM available to a Java process can vary.  The customer would like to use as much available RAM as possible rather than counting on ergonomics to pick the amount for them.

The -XX:Min/MaxRAMFraction options come close to providing what the customer wants but they would either prefer a new set of flags that would represent a % of total rather than a ratio or they would be ok if we change the existing flags to a floating point value.  The new flag could be named -XX:MaxRAMPercentage=xx



Comments
I proposal to add these new flags instead of altering the existing one and will mark the existing flags as deprecated. -XX:MaxRAMPercentage -XX:MinRAMPercentage -XX:InitialRAMPercentage With values ranging from 1 to 100.
21-08-2017