You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In order to make stored String values into DocValues, all the Strings are kept in a TreeSet<BytesRef>. The overhead is very large, as 1MB of heap can hold only 6500 values. Having 1M unique stored values in a field requires 153MB of heap.
Most of the memory is used for Java Objects and references, not the characters themselves. Storing the BytesRef in a BytesRef-array and keeping track of ordering and duplicates with a heap of native longs would be one memory-saving solution.
The text was updated successfully, but these errors were encountered:
In order to make stored String values into DocValues, all the Strings are kept in a
TreeSet<BytesRef>
. The overhead is very large, as 1MB of heap can hold only 6500 values. Having 1M unique stored values in a field requires 153MB of heap.Most of the memory is used for Java Objects and references, not the characters themselves. Storing the BytesRef in a BytesRef-array and keeping track of ordering and duplicates with a heap of native
long
s would be one memory-saving solution.The text was updated successfully, but these errors were encountered: