guluo created HBASE-29767:
-----------------------------
Summary: Fix IOTimePerHit NaN issue in BucketCacheStats
Key: HBASE-29767
URL: https://issues.apache.org/jira/browse/HBASE-29767
Project: HBase
Issue Type: Improvement
Components: BlockCache
Reporter: guluo
When we enable L2 Block cache, if we did not perform any scan, we may get the
following logs.
INFO [BucketCacheStatsExecutor] bucket.BucketCache: failedBlockAdditions=0,
totalSize=98.19 MB, freeSize=98.18 MB, usedSize=15 KB, cacheSize=3.83 KB,
accesses=12, hits=6, IOhitsPerSecond=0, {color:#FF0000}IOTimePerHit=NaN{color},
hitRatio=50.00%, cachingAccesses=12, cachingHits=6, cachingHitsRatio=50.00%,
evictions=0, evicted=0, evictedPerRun=0.0, allocationFailCount=0
And we open UI of RegionServer, and would found the Time per Hit also dispalys
NaN
--
This message was sent by Atlassian Jira
(v8.20.10#820010)