public class MemoryPool extends Object
| Constructor and Description |
|---|
MemoryPool(MemoryPoolId id,
io.airlift.units.DataSize size) |
| Modifier and Type | Method and Description |
|---|---|
void |
addListener(MemoryPoolListener listener) |
void |
free(QueryId queryId,
String allocationTag,
long bytes) |
void |
freeRevocable(QueryId queryId,
long bytes) |
long |
getFreeBytes()
Returns the number of free bytes.
|
MemoryPoolId |
getId() |
MemoryPoolInfo |
getInfo() |
long |
getMaxBytes() |
long |
getReservedBytes() |
long |
getReservedRevocableBytes() |
void |
removeListener(MemoryPoolListener listener) |
com.google.common.util.concurrent.ListenableFuture<?> |
reserve(QueryId queryId,
String allocationTag,
long bytes)
Reserves the given number of bytes.
|
com.google.common.util.concurrent.ListenableFuture<?> |
reserveRevocable(QueryId queryId,
long bytes) |
String |
toString() |
boolean |
tryReserve(QueryId queryId,
String allocationTag,
long bytes)
Try to reserve the given number of bytes.
|
public MemoryPool(MemoryPoolId id, io.airlift.units.DataSize size)
public MemoryPoolId getId()
public MemoryPoolInfo getInfo()
public void addListener(MemoryPoolListener listener)
public void removeListener(MemoryPoolListener listener)
public com.google.common.util.concurrent.ListenableFuture<?> reserve(QueryId queryId, String allocationTag, long bytes)
public com.google.common.util.concurrent.ListenableFuture<?> reserveRevocable(QueryId queryId, long bytes)
public boolean tryReserve(QueryId queryId, String allocationTag, long bytes)
public void freeRevocable(QueryId queryId, long bytes)
public long getFreeBytes()
public long getMaxBytes()
public long getReservedBytes()
public long getReservedRevocableBytes()
Copyright © 2012–2019. All rights reserved.