public interface PageMemoryEx extends PageMemory
FLAG_AUX, FLAG_DATA, FLAG_IDX, INDEX_PARTITION, MAX_PARTITION_ID, META_PAGE_ID| Modifier and Type | Method and Description |
|---|---|
long |
acquirePage(int grpId,
long pageId,
AtomicBoolean pageAllocated) |
long |
acquirePage(int grpId,
long pageId,
IoStatisticsHolder statHldr,
boolean restore) |
GridMultiCollectionWrapper<FullPageId> |
beginCheckpoint(IgniteInternalFuture allowToReplace)
Gets a collection of dirty page IDs since the last checkpoint.
|
void |
checkpointWritePage(FullPageId pageId,
ByteBuffer buf,
PageStoreWriter pageWriter,
CheckpointMetricsTracker tracker)
Prepare page for write during checkpoint.
|
IgniteInternalFuture<Void> |
clearAsync(LoadedPagesMap.KeyPredicate pred,
boolean cleanDirty)
Asynchronously clears pages satisfying the given predicate.
|
void |
finishCheckpoint()
Finishes checkpoint operation.
|
int |
invalidate(int grpId,
int partId)
Marks partition as invalid / outdated.
|
void |
onCacheGroupDestroyed(int grpId)
Clears internal metadata of destroyed cache group.
|
PageReadWriteManager |
pageManager() |
long |
partitionMetaPageId(int grpId,
int partId)
Gets partition metadata page for specified grpId and partId.
|
FullPageId |
pullPageFromCpBuffer()
Pull page from checkpoint buffer.
|
long |
readLock(long absPtr,
long pageId,
boolean force,
boolean touch) |
boolean |
safeToUpdate()
Heuristic method which allows a thread to check if it safe to start memory struture modifications
in regard with checkpointing.
|
boolean |
shouldThrottle()
Calculates throttling condition.
|
long |
totalPages()
Total pages can be placed to memory.
|
long |
writeLock(int grpId,
long pageId,
long page,
boolean restore) |
void |
writeUnlock(int grpId,
long pageId,
long page,
Boolean walPlc,
boolean dirtyFlag,
boolean restore) |
checkpointBufferPagesCount, loadedPages, metrics, pageBuffer, pageSize, realPageSize, start, stop, systemPageSizeallocatePage, freePageacquirePage, acquirePage, isDirty, readLock, readLockForce, readUnlock, releasePage, tryWriteLock, writeLock, writeUnlocklong readLock(long absPtr,
long pageId,
boolean force,
boolean touch)
absPtr - Absolute pointer to read lock.pageId - Page ID.force - Force flag.touch - Update page timestamp.long writeLock(int grpId,
long pageId,
long page,
boolean restore)
grpId - Group ID.pageId - Page ID.page - Page pointer.restore - Determines if the page is locked for restore memory (crash recovery).void writeUnlock(int grpId,
long pageId,
long page,
Boolean walPlc,
boolean dirtyFlag,
boolean restore)
grpId - Group ID.pageId - Page ID.page - Page pointer.walPlc - True if page should be recorded to WAL, false if the page must not
be recorded and null for the default behavior.dirtyFlag - Determines whether the page was modified since the last checkpoint.restore - Determines if the page is locked for restore.long partitionMetaPageId(int grpId,
int partId)
grpId - Group ID.partId - Partition ID.long acquirePage(int grpId,
long pageId,
AtomicBoolean pageAllocated)
throws IgniteCheckedException
grpId - Cache group ID.pageId - Page ID.pageAllocated - Flag is set if new page was allocated in offheap memory.IgniteCheckedExceptionSets additional flag indicating that page was not found in memory and had to be allocated.long acquirePage(int grpId,
long pageId,
IoStatisticsHolder statHldr,
boolean restore)
throws IgniteCheckedException
grpId - Cache group ID.pageId - Page id.restore - Get page for restoreIgniteCheckedException - If failed.StorageException - If page reading failed from storage.Will read page from file if it is not present in memoryboolean safeToUpdate()
False if there are too many dirty pages and a thread should wait for a
checkpoint to begin.GridMultiCollectionWrapper<FullPageId> beginCheckpoint(IgniteInternalFuture allowToReplace) throws IgniteException
allowToReplace - The sign which allows to replace pages from a checkpoint by page replacer.IgniteException - If checkpoint has been already started and was not finished.void finishCheckpoint()
void checkpointWritePage(FullPageId pageId, ByteBuffer buf, PageStoreWriter pageWriter, CheckpointMetricsTracker tracker) throws IgniteCheckedException
PageStoreWriter will be called when the page will be ready to write.pageId - Page ID to get byte buffer for. The page ID must be present in the collection returned by
the beginCheckpoint(IgniteInternalFuture) method call.buf - Temporary buffer to write changes into.pageWriter - Checkpoint page write context.tracker - Checkpoint metrics tracker.IgniteCheckedException - If failed to obtain page data.PageReadWriteManager pageManager()
int invalidate(int grpId,
int partId)
grpId - Group ID.partId - Partition ID.void onCacheGroupDestroyed(int grpId)
grpId - Cache group ID.IgniteInternalFuture<Void> clearAsync(LoadedPagesMap.KeyPredicate pred, boolean cleanDirty)
pred - Predicate for cache group id, pageId.cleanDirty - Flag indicating that dirty pages collection should be cleaned.FullPageId pullPageFromCpBuffer()
boolean shouldThrottle()
long totalPages()
Follow @ApacheIgnite
Ignite Database and Caching Platform : ver. 2.11.0 Release Date : September 11 2021