javanna commented on PR #16000: URL: https://github.com/apache/lucene/pull/16000#issuecomment-4405383587
I did some more research and found maybe some discrepancy in `ByteBuffersDataInput` and `ByteBuffersDataOutput` (and indirectly `PrefixCodedTerm` as well as `NRTCachingDirectory`): these are allocator-agnostic and would count off-heap if constructed with a direct allocator. These look more like edge cases / exceptions, as the vast majority of the `Accountable` implementations either only use heap memory, or consciously leave out the off-heap memory they use in their `ramBytesUsed` implementation. (`OffHeapFSTStore` , `DirectPackedReader`, `LegacyDirectMonotonicReader`). VectorsReader impls all consistently report on heap only by design. `KnnVectorDict.ramBytesUsed()` unambiguously includes off-heap (mmap) bytes today, but it does not implement `Accountable`. That's perhaps a good candidate for renaming to avoid confusion? -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
