public long getMaxMemory() {
    return maxMemory;
  }
Returns the maximum number of megabytes of memory available from the operating system.

@return the maximum number of megabytes of memory available from the operating system
geode-core/src/main/java/org/apache/geode/management/JVMMetrics.java