lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Adrien Grand <>
Subject Confusing method names to get the size of objects
Date Fri, 08 Jun 2012 10:20:32 GMT

Lucene and Solr have a few classes that expose the size of their
instances, but with different method names. There are at least
ramBytesUsed (packed ints), sizeInBytes (FST, RamDirectory) and
memSize (Solr DocSets) that provide an estimation of the memory used
in bytes. The confusing thing is that sizeInBytes is sometimes also
used for on-disk sizes (SegmentInfo for example). I think it would
improve readability to stick to only two method names, one for the
in-memory size and one for the on-disk size. Or maybe these methods
have different meanings that I am missing? What do you think?


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message