Skip to content

HBASE-30453 BucketCache region cached size is not decremented on eviction for non-persistent IOEngines - #8737

Open
julianchandras wants to merge 1 commit into
apache:masterfrom
julianchandras:HBASE-30453
Open

julianchandras wants to merge 1 commit into
apache:masterfrom
julianchandras:HBASE-30453

Conversation

@julianchandras

Copy link
Copy Markdown

JIRA: https://issues.apache.org/jira/browse/HBASE-30432

regionCachedSize was decremented only in fileNotFullyCached, which blockEvicted calls only for persistent IOEngines, so offheap evictions were never subtracted. Moved the decrement into blockEvicted to mirror the increment in putIntoBackingMap.

This also fixes a double decrement in the persistent cache validation thread (evictBlock followed by fileNotFullyCached) that occurred before the fix.

Tests:

  • TestBucketCache#testRegionCachedSizeDecrementedOnEvictionForNonPersistentEngine
  • TestVerifyBucketCacheFile#testRegionCachedSizeAfterInvalidBlockEvictedOnValidation (double decrement)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant