public interface PageMemoryEx extends PageMemory
FLAG_DATA, FLAG_IDX, INDEX_PARTITION, MAX_PARTITION_ID, METASTORE_PARTITION, OLD_METASTORE_PARTITION| Modifier and Type | Method and Description |
|---|---|
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.
|
long |
metaPageId(int grpId)
Gets or allocates metadata page for specified grpId.
|
void |
onCacheGroupDestroyed(int grpId)
Clears internal metadata of destroyed cache group.
|
long |
partitionMetaPageId(int grpId,
int partId)
Gets or allocates partition metadata page for specified grpId and partId.
|
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.
|
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, 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 metaPageId(int grpId)
throws IgniteCheckedException
grpId - Group ID.IgniteCheckedException - If failed.long partitionMetaPageId(int grpId,
int partId)
throws IgniteCheckedException
grpId - Group ID.partId - Partition ID.IgniteCheckedException - If failed.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.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.long totalPages()
Follow @ApacheIgnite
Ignite Database and Caching Platform : ver. 2.8.1 Release Date : May 21 2020