Class MemoryLimiter
java.lang.Object
org.apache.dubbo.common.threadpool.MemoryLimiter
memory limiter.
-
Constructor Summary
ConstructorsConstructorDescriptionMemoryLimiter(long memoryLimit, Instrumentation inst) MemoryLimiter(Instrumentation inst) -
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleanvoidvoidclear()longlonglongvoidvoidvoidreleaseInterruptibly(Object e, long timeout, TimeUnit unit) voidsetMemoryLimit(long memoryLimit)
-
Constructor Details
-
MemoryLimiter
-
MemoryLimiter
-
-
Method Details
-
setMemoryLimit
public void setMemoryLimit(long memoryLimit) -
getMemoryLimit
public long getMemoryLimit() -
getCurrentMemory
public long getCurrentMemory() -
getCurrentRemainMemory
public long getCurrentRemainMemory() -
acquire
-
acquireInterruptibly
- Throws:
InterruptedException
-
acquire
- Throws:
InterruptedException
-
release
-
releaseInterruptibly
- Throws:
InterruptedException
-
releaseInterruptibly
- Throws:
InterruptedException
-
clear
public void clear()
-