A large number of query terms is definitely an anti-pattern and not a recommended use case for Solr, but I'm a little surprised that it takes minutes, as opposed to 10 to 20 seconds.

Does your index fit entirely in the OS system memory available for file caching?

IOW, are those "few minutes" CPU-bound or I/O-bound?

-- Jack Krupansky

-----Original Message----- From: SolrUser1543
Sent: Tuesday, August 19, 2014 2:57 PM
To: solr-user@lucene.apache.org
Subject: Performance of Boolean query with hundreds of OR clauses.

I am using Solr to perform search for finding similar pictures.

For this purpose, every image indexed as a set of descriptors ( descriptor
is a string of 6 chars ) .
Number of descriptors for every image may vary ( from few to many thousands)

When I want to search  for a similar image , I am extracting the descriptors
from it and create a query like :
MyImage:( desc1 desc2 ...  desc n )

Number of descriptors in query may also vary. Usual it is about 1000.

Of course performance of this query very bad and may take few minutes to
return .

Any ideas for performance improvement ?

P.s I also tried to use lire , but it is not fits my use case.



--
View this message in context: http://lucene.472066.n3.nabble.com/Performance-of-Boolean-query-with-hundreds-of-OR-clauses-tp4153844.html Sent from the Solr - User mailing list archive at Nabble.com.

Reply via email to