lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Luke Francl <>
Subject Understanding TooManyClauses-Exception and Query-RAM-size
Date Mon, 15 Nov 2004 22:45:52 GMT
In a July 2004 message
but the list archives seem to be down right now), Martin Stein quoted
Doug Cutting as giving this formula to estimate the amount of memory
consumed by a query:

1 byte * Number of searchable fields in your index * Number of docs in
your index


1k bytes * number of terms in query


1k bytes * number of phrase terms in query

I'm adding some features to LIMO, and query RAM estimation is one of

However, I'm not quite sure about how to calculate the first term in
this formula. I'm calculating the memory used recursively. Does the
first part apply to every Query object, or only to the entire Query

For example, with a query like "foo" on an index with 10 fields and 1000
documents, the memory used would = 1*10*1000 + 1024*1 = 11024.
But for the query "foo +(bar baz)" do you include number_of_fields *
number_of_documents part for each term in the query? Or just for the
entire thing?

Luke Francl

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

View raw message