Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
-
None
Description
Orc footer cache has a calculation of memory usage:
public int getMemoryUsage() { return bb.remaining() + 100; // 100 is for 2 longs, BB and java overheads (semi-arbitrary). }
ByteBuffer.remaining returns the remaining space in the bytebuffer, thus allowing this cache have elements MAXWEIGHT/100 of arbitrary size. I think the correct solution would be bb.capacity.