public interface BufferManager extends StorageManager, TupleBufferCache
storage managers
to retrieve data, store data, and
transfer data. The buffer manager has algorithms that tell it when and
how to store data. The buffer manager should also be aware of memory
management issues.Modifier and Type | Interface and Description |
---|---|
static class |
BufferManager.BufferReserveMode |
static class |
BufferManager.TupleSourceType |
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_MAX_PROCESSING_KB |
static int |
DEFAULT_PROCESSOR_BATCH_SIZE |
static int |
DEFAULT_RESERVE_BUFFER_KB |
Modifier and Type | Method and Description |
---|---|
void |
addTupleBuffer(TupleBuffer tb) |
FileStore |
createFileStore(String name)
Creates a new
FileStore . |
STree |
createSTree(List<? extends Expression> elements,
String groupName,
int keyLength) |
TupleBuffer |
createTupleBuffer(List elements,
String groupName,
BufferManager.TupleSourceType tupleSourceType) |
int |
getMaxProcessingSize()
Return the max that can be temporarily held potentially
across even a blocked exception.
|
Options |
getOptions() |
int |
getProcessorBatchSize()
Get the nominal batch size target
|
int |
getProcessorBatchSize(List<? extends Expression> schema)
Get the batch size to use during query processing.
|
int |
getSchemaSize(List<? extends Expression> elements)
Get the size estimate for the given schema.
|
void |
persistLob(Streamable<?> lob,
FileStore store,
byte[] bytes) |
void |
releaseBuffers(int count)
Releases the buffers reserved by a call to
BufferManager#reserveBuffers(int, boolean) |
void |
releaseOrphanedBuffers(long count) |
int |
reserveBuffers(int count,
BufferManager.BufferReserveMode mode)
Reserve up to count buffers for use.
|
int |
reserveBuffersBlocking(int count,
long[] attempts,
boolean force) |
void |
setMaxActivePlans(int maxActivePlans)
Set the maxActivePlans as a hint at determining the maxProcessing
|
void |
setOptions(Options options) |
getMaxStorageSpace, initialize
distributeTupleBuffer, getTupleBuffer
static final int DEFAULT_PROCESSOR_BATCH_SIZE
static final int DEFAULT_MAX_PROCESSING_KB
static final int DEFAULT_RESERVE_BUFFER_KB
int getProcessorBatchSize(List<? extends Expression> schema)
int getProcessorBatchSize()
TupleBuffer createTupleBuffer(List elements, String groupName, BufferManager.TupleSourceType tupleSourceType) throws TeiidComponentException
TeiidComponentException
int getMaxProcessingSize()
FileStore createFileStore(String name)
FileStore
. See FileStore#setCleanupReference(Object)
to
automatically cleanup the underlying resources.createFileStore
in interface StorageManager
name
- int reserveBuffers(int count, BufferManager.BufferReserveMode mode)
count
- mode
- void releaseBuffers(int count)
BufferManager#reserveBuffers(int, boolean)
count
- int getSchemaSize(List<? extends Expression> elements)
STree createSTree(List<? extends Expression> elements, String groupName, int keyLength)
void addTupleBuffer(TupleBuffer tb)
void setMaxActivePlans(int maxActivePlans)
maxActivePlans
- void setOptions(Options options)
void persistLob(Streamable<?> lob, FileStore store, byte[] bytes) throws TeiidComponentException
TeiidComponentException
int reserveBuffersBlocking(int count, long[] attempts, boolean force) throws BlockedException
BlockedException
void releaseOrphanedBuffers(long count)
Options getOptions()
Copyright © 2019. All rights reserved.