You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@accumulo.apache.org by "ArbaazKhan1 (via GitHub)" <gi...@apache.org> on 2026/08/13 22:21:20 UTC
[PR] New option to cache data [accumulo]
ArbaazKhan1 opened a new pull request, #6500:
URL: https://github.com/apache/accumulo/pull/6500
Closes [issue #6023 ](https://github.com/apache/accumulo/issues/6023)
Implements a new optional compressed block cache for `RFile` blocks. Currently Accumulo's primary block cache stores uncompressed blocks for tablets with high compression ratios. This means cached data takes up more space on the Heap than the corresponding on-disk footprint, reducing the number of distinct blocks that can be held in memory.
The changes here add an optional compressed data cache to `TabletServers` and `ScanServers`. When enabled blocks are compressed before being stored in the secondary cache and transparently decompressed when read. The feature is disabled by default, so existing deployments are unchanged unless the new properties are used.
Changes:
- Added `CompressedBlockCache` to compress blocks before storing them and decompressing them on retrieval
- Added configurable cache sized for Tablet and Scan servers
- Added a secondary cache lookup path: primary cache → compressed cache → disk.
- Blocks retrieved from the compressed cache are decompressed and promoted back into the primary cache.
- Updated the cache provider and TabletServer resource management to support the new cache.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@accumulo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] New option to cache data [accumulo]
Posted by "dlmarion (via GitHub)" <gi...@apache.org>.
dlmarion commented on PR #6500:
URL: https://github.com/apache/accumulo/pull/6500#issuecomment-5316640768
Reading over @keith-turner's notes in #6023, I'm not sure that this is the implementation that he envisioned. He said,
> This could potentially be implemented without any changes to Accumulo. The only drawback to that is we would always uncompress the data when reading from disk and then recompress it when storing in the cache. This could be expensive. To allow taking compressed rfile blocks directly from disk and storing them in cache would require a change in Accumulo because it always uncompresses before caching.
> Maybe its best to leave the on heap primary cache as uncompressed and have a secondary cache (possibly off heap) that compresses blocks. This could likely be done w/o any changes to Accumulo as it could be done completely by plugins.
Accumulo has a [Block Cache Manager SPI](https://github.com/apache/accumulo/blob/main/core/src/main/java/org/apache/accumulo/core/spi/cache/BlockCacheManager.java) and provides two implementations (Lru and TinyLFU) that store uncompressed cached blocks on heap. There are also two other implementations that use the on-heap block cache as a L1 cache and then use some other facility for storing blocks off-heap. Those implementations are https://github.com/keith-turner/accumulo-ohc and https://github.com/dlmarion/accumulo-shared-offheap-cache.
I think what @keith-turner was suggesting is that the SPI implementation could cache the off-heap blocks in a compressed manner and handle the compression / decompression. This would likely require no changes to Accumulo code.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@accumulo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org