public class MemoryLimitCalculator
extends java.lang.Object
MXBean technology is used to calculate the memory
limit by using the percentage of the current maximum available memory,
which can be used with MemoryLimiter.MemoryLimiter| 构造器和说明 |
|---|
MemoryLimitCalculator() |
| 限定符和类型 | 方法和说明 |
|---|---|
static long |
calculate(float percentage)
Take the current JVM's maximum available memory
as a percentage of the result as the limit.
|
static long |
defaultLimit()
By default, it takes 80% of the maximum available memory of the current JVM.
|
static long |
maxAvailable()
Get the maximum available memory of the current JVM.
|
public static long maxAvailable()
public static long calculate(float percentage)
percentage - percentagepublic static long defaultLimit()
Copyright © 2022 The Apache Software Foundation. All rights reserved.