public class DataStorageMetricsImpl extends Object implements DataStorageMetricsMXBean
| Modifier and Type | Field and Description |
|---|---|
static String |
DATASTORAGE_METRIC_PREFIX
Prefix for all data storage metrics.
|
| Constructor and Description |
|---|
DataStorageMetricsImpl(GridMetricManager mmgr,
boolean metricsEnabled,
long rateTimeInterval,
int subInts) |
| Modifier and Type | Method and Description |
|---|---|
void |
disableMetrics()
Disables persistence metrics collection on an Apache Ignite node.
|
void |
enableMetrics()
Enables persistence metrics collection on an Apache Ignite node.
|
long |
getCheckpointBufferSize()
Checkpoint buffer size in bytes.
|
long |
getCheckpointTotalTime()
Total checkpoint time from last restart.
|
long |
getDirtyPages()
Total dirty pages for the next checkpoint.
|
long |
getLastCheckpointCopiedOnWritePagesNumber()
Gets the number of pages copied to a temporary checkpoint buffer during the last checkpoint.
|
long |
getLastCheckpointDataPagesNumber()
Gets the number of data pages written during the last checkpoint.
|
long |
getLastCheckpointDuration()
Gets the duration of the last checkpoint in milliseconds.
|
long |
getLastCheckpointFsyncDuration()
Gets the duration of the sync phase of the last checkpoint in milliseconds.
|
long |
getLastCheckpointLockWaitDuration()
Gets the duration of last checkpoint lock wait in milliseconds.
|
long |
getLastCheckpointMarkDuration()
Gets the duration of last checkpoint mark phase in milliseconds.
|
long |
getLastCheckpointPagesWriteDuration()
Gets the duration of last checkpoint pages write phase in milliseconds.
|
long |
getLastCheckpointStarted()
Returns time when the last checkpoint was started.
|
long |
getLastCheckpointTotalPagesNumber()
Gets the total number of pages written during the last checkpoint.
|
long |
getOffHeapSize()
Total offheap size in bytes.
|
long |
getOffheapUsedSize()
Total used offheap size in bytes.
|
long |
getPagesRead()
The number of read pages from last restart.
|
long |
getPagesReplaced()
The number of replaced pages from last restart.
|
long |
getPagesWritten()
The number of written pages from last restart.
|
long |
getSparseStorageSize()
Storage space allocated adjusted for possible sparsity in bytes.
|
long |
getStorageSize()
Storage space allocated in bytes.
|
long |
getTotalAllocatedSize()
Total size of memory allocated in bytes.
|
long |
getUsedCheckpointBufferPages()
Gets used checkpoint buffer size in pages.
|
long |
getUsedCheckpointBufferSize()
Gets used checkpoint buffer size in bytes.
|
int |
getWalArchiveSegments()
Gets the current number of WAL segments in the WAL archive.
|
long |
getWalBuffPollSpinsRate()
Returns WAL buffer poll spins number over the last time interval.
|
long |
getWalCompressedBytes()
Getting the total size of the compressed segments in bytes.
|
float |
getWalFsyncTimeAverage()
Gets the average WAL fsync duration in microseconds over the last time interval.
|
long |
getWalLastRollOverTime()
Time of the last WAL segment rollover.
|
float |
getWalLoggingRate()
Gets the average number of WAL records per second written during the last time interval.
|
long |
getWalTotalSize()
Total size in bytes for storage wal files.
|
float |
getWalWritingRate()
Gets the average number of bytes per second written during the last time interval.
|
long |
getWalWrittenBytes()
Getting the total number of logged bytes into the WAL.
|
boolean |
metricsEnabled() |
void |
onBuffPollSpin(int num) |
void |
onCheckpoint(long beforeLockDuration,
long lockWaitDuration,
long listenersExecuteDuration,
long markDuration,
long lockHoldDuration,
long pagesWriteDuration,
long fsyncDuration,
long walRecordFsyncDuration,
long writeEntryDuration,
long splitAndSortPagesDuration,
long duration,
long start,
long totalPages,
long dataPages,
long cowPages) |
void |
onFsync(long nanoTime) |
void |
onStorageSizeChanged(long storageSize,
long sparseStorageSize) |
void |
onWalBytesWritten(int size) |
void |
onWallRollOver() |
void |
onWalRecordLogged(long size)
Callback on logging a record to a WAL.
|
void |
onWalSegmentCompressed(long size)
Callback on compression of a WAL segment.
|
void |
rateTimeInterval(long rateTimeInterval)
Sets time interval for rate-based metrics.
|
void |
regionMetrics(Collection<DataRegionMetrics> regionMetrics) |
void |
setWalSizeProvider(IgniteOutClosure<Long> walSizeProvider) |
void |
subIntervals(int subInts)
Sets a number of sub-intervals the whole
DataStorageMetricsMXBean.rateTimeInterval(long) will be split into to calculate
rate-based metrics. |
void |
wal(IgniteWriteAheadLogManager wal) |
public static final String DATASTORAGE_METRIC_PREFIX
public DataStorageMetricsImpl(GridMetricManager mmgr, boolean metricsEnabled, long rateTimeInterval, int subInts)
mmgr - Metrics manager.metricsEnabled - Metrics enabled flag.rateTimeInterval - Rate time interval.subInts - Number of sub-intervals.public float getWalLoggingRate()
The length of time interval is configured via DataStorageConfiguration.setMetricsRateTimeInterval(long)
configuration property.
The number of subintervals is configured via DataStorageConfiguration.setMetricsSubIntervalCount(int)
configuration property.
getWalLoggingRate in interface DataStorageMetricsgetWalLoggingRate in interface DataStorageMetricsMXBeanpublic float getWalWritingRate()
DataStorageConfiguration.setMetricsRateTimeInterval(long)
configuration property.
The number of subintervals is configured via DataStorageConfiguration.setMetricsSubIntervalCount(int)
configuration property.getWalWritingRate in interface DataStorageMetricsgetWalWritingRate in interface DataStorageMetricsMXBeanpublic int getWalArchiveSegments()
getWalArchiveSegments in interface DataStorageMetricsgetWalArchiveSegments in interface DataStorageMetricsMXBeanpublic float getWalFsyncTimeAverage()
The length of time interval is configured via DataStorageConfiguration.setMetricsRateTimeInterval(long)
configuration property.
The number of subintervals is configured via DataStorageConfiguration.setMetricsSubIntervalCount(int)
configuration property.
getWalFsyncTimeAverage in interface DataStorageMetricsgetWalFsyncTimeAverage in interface DataStorageMetricsMXBeanpublic long getWalBuffPollSpinsRate()
The length of time interval is configured via DataStorageConfiguration.setMetricsRateTimeInterval(long)
configuration property.
The number of subintervals is configured via DataStorageConfiguration.setMetricsSubIntervalCount(int)
configuration property.
getWalBuffPollSpinsRate in interface DataStorageMetricsgetWalBuffPollSpinsRate in interface DataStorageMetricsMXBeanpublic long getLastCheckpointDuration()
getLastCheckpointDuration in interface DataStorageMetricsgetLastCheckpointDuration in interface DataStorageMetricsMXBeanpublic long getLastCheckpointStarted()
getLastCheckpointStarted in interface DataStorageMetricsgetLastCheckpointStarted in interface DataStorageMetricsMXBeanpublic long getLastCheckpointLockWaitDuration()
getLastCheckpointLockWaitDuration in interface DataStorageMetricsgetLastCheckpointLockWaitDuration in interface DataStorageMetricsMXBeanpublic long getLastCheckpointMarkDuration()
getLastCheckpointMarkDuration in interface DataStorageMetricsgetLastCheckpointMarkDuration in interface DataStorageMetricsMXBeanpublic long getLastCheckpointPagesWriteDuration()
getLastCheckpointPagesWriteDuration in interface DataStorageMetricsgetLastCheckpointPagesWriteDuration in interface DataStorageMetricsMXBeanpublic long getLastCheckpointFsyncDuration()
getLastCheckpointFsyncDuration in interface DataStorageMetricsgetLastCheckpointFsyncDuration in interface DataStorageMetricsMXBeanpublic long getLastCheckpointTotalPagesNumber()
getLastCheckpointTotalPagesNumber in interface DataStorageMetricsgetLastCheckpointTotalPagesNumber in interface DataStorageMetricsMXBeanpublic long getLastCheckpointDataPagesNumber()
getLastCheckpointDataPagesNumber in interface DataStorageMetricsgetLastCheckpointDataPagesNumber in interface DataStorageMetricsMXBeanpublic long getLastCheckpointCopiedOnWritePagesNumber()
getLastCheckpointCopiedOnWritePagesNumber in interface DataStorageMetricsgetLastCheckpointCopiedOnWritePagesNumber in interface DataStorageMetricsMXBeanpublic void enableMetrics()
enableMetrics in interface DataStorageMetricsMXBeanpublic void disableMetrics()
disableMetrics in interface DataStorageMetricsMXBeanpublic void rateTimeInterval(long rateTimeInterval)
DataStorageConfiguration.setMetricsRateTimeInterval(long) configuration property.rateTimeInterval in interface DataStorageMetricsMXBeanrateTimeInterval - Time interval (in milliseconds) used for allocation and eviction rates calculations.public void subIntervals(int subInts)
DataStorageMetricsMXBean.rateTimeInterval(long) will be split into to calculate
rate-based metrics. Identical to setting DataStorageConfiguration.setMetricsSubIntervalCount(int) configuration
property.subIntervals in interface DataStorageMetricsMXBeansubInts - A number of sub-intervals.public long getWalTotalSize()
getWalTotalSize in interface DataStorageMetricsgetWalTotalSize in interface DataStorageMetricsMXBeanpublic long getWalLastRollOverTime()
getWalLastRollOverTime in interface DataStorageMetricsgetWalLastRollOverTime in interface DataStorageMetricsMXBeanpublic long getCheckpointTotalTime()
getCheckpointTotalTime in interface DataStorageMetricsgetCheckpointTotalTime in interface DataStorageMetricsMXBeanpublic long getDirtyPages()
getDirtyPages in interface DataStorageMetricsgetDirtyPages in interface DataStorageMetricsMXBeanpublic long getPagesRead()
getPagesRead in interface DataStorageMetricsgetPagesRead in interface DataStorageMetricsMXBeanpublic long getPagesWritten()
getPagesWritten in interface DataStorageMetricsgetPagesWritten in interface DataStorageMetricsMXBeanpublic long getPagesReplaced()
getPagesReplaced in interface DataStorageMetricsgetPagesReplaced in interface DataStorageMetricsMXBeanpublic long getOffHeapSize()
getOffHeapSize in interface DataStorageMetricsgetOffHeapSize in interface DataStorageMetricsMXBeanpublic long getOffheapUsedSize()
getOffheapUsedSize in interface DataStorageMetricsgetOffheapUsedSize in interface DataStorageMetricsMXBeanpublic long getTotalAllocatedSize()
getTotalAllocatedSize in interface DataStorageMetricsgetTotalAllocatedSize in interface DataStorageMetricsMXBeanpublic long getUsedCheckpointBufferPages()
getUsedCheckpointBufferPages in interface DataStorageMetricsgetUsedCheckpointBufferPages in interface DataStorageMetricsMXBeanpublic long getUsedCheckpointBufferSize()
getUsedCheckpointBufferSize in interface DataStorageMetricsgetUsedCheckpointBufferSize in interface DataStorageMetricsMXBeanpublic long getCheckpointBufferSize()
getCheckpointBufferSize in interface DataStorageMetricsgetCheckpointBufferSize in interface DataStorageMetricsMXBeanpublic void wal(IgniteWriteAheadLogManager wal)
wal - Write-ahead log manager.public void setWalSizeProvider(IgniteOutClosure<Long> walSizeProvider)
walSizeProvider - Wal size provider.public void onWallRollOver()
public void regionMetrics(Collection<DataRegionMetrics> regionMetrics)
public boolean metricsEnabled()
public long getStorageSize()
getStorageSize in interface DataStorageMetricsgetStorageSize in interface DataStorageMetricsMXBeanpublic long getSparseStorageSize()
getSparseStorageSize in interface DataStorageMetricsgetSparseStorageSize in interface DataStorageMetricsMXBeanpublic void onCheckpoint(long beforeLockDuration,
long lockWaitDuration,
long listenersExecuteDuration,
long markDuration,
long lockHoldDuration,
long pagesWriteDuration,
long fsyncDuration,
long walRecordFsyncDuration,
long writeEntryDuration,
long splitAndSortPagesDuration,
long duration,
long start,
long totalPages,
long dataPages,
long cowPages)
beforeLockDuration - Checkpoint action before taken write lock duration.lockWaitDuration - Lock wait duration.listenersExecuteDuration - Execution listeners under write lock duration.markDuration - Mark duration.lockHoldDuration - Lock hold duration.pagesWriteDuration - Pages write duration.fsyncDuration - Total checkpoint fsync duration.walRecordFsyncDuration - Duration of WAL fsync after logging CheckpointRecord on checkpoint begin.writeEntryDuration - Duration of checkpoint entry buffer writing to file.splitAndSortPagesDuration - Duration of splitting and sorting checkpoint pages.duration - Total checkpoint duration.start - Checkpoint start time.totalPages - Total number of all pages in checkpoint.dataPages - Total number of data pages in checkpoint.cowPages - Total number of COW-ed pages in checkpoint.public void onStorageSizeChanged(long storageSize,
long sparseStorageSize)
sparseStorageSize - Sparse storage size.storageSize - Storage size.public void onWalRecordLogged(long size)
size - Record size in bytes.public void onWalBytesWritten(int size)
size - Size written.public void onFsync(long nanoTime)
nanoTime - Fsync nano time.public void onBuffPollSpin(int num)
num - Number.public long getWalWrittenBytes()
getWalWrittenBytes in interface DataStorageMetricsgetWalWrittenBytes in interface DataStorageMetricsMXBeanpublic long getWalCompressedBytes()
getWalCompressedBytes in interface DataStorageMetricsgetWalCompressedBytes in interface DataStorageMetricsMXBeanpublic void onWalSegmentCompressed(long size)
size - Size of the compressed segment in bytes.
Follow @ApacheIgnite
Ignite Database and Caching Platform : ver. 2.11.1 Release Date : December 20 2021