Hi all, I have a patch for SOLR-1093. It isnt a complete solution but close. The sub queries are run serially as Lance Norskog<https://issues.apache.org/jira/secure/ViewProfile.jspa?name=lancenorskog> mention's in his comment on 23/Dec/09. It has been very useful for us and would like to submit the patch. I sent an email to the list about a couple of months back http://lucene.472066.n3.nabble.com/Implementing-SOLR-1093-td3871919.html but I havent heard back yet. Following is the information about the patch. Please do let me know if you have any concerns. I will wait for a week and if I don hear any concerns, I am planning to submit the patch.
*Implementation* I have created a new class MultiSearchHandler which is an extension of SearchHandler. It takes all the parameters that a SearchHandler can take and parses them into sub queries(LocalSolrQueryRequests). It then executes each of these sub queries using the SearchHandler. It doesnt enforce IndexSearcher consistency amongnst multiple queries within the same request (This doesnt harm us and is infact good for our usecase). *Usage* To pass a parameter an individual query, it should be prefixed with the query number Eg. 1.q=”query1”&2.q=”query2”…. To pass a parameter to all queries, the prefix shouldn’t be specified Eg. count=2&query=”query1”&1.mm=3&2.mm=2…. * * *New query parameters specific to MultiSearchHandler * In addition to all the parameters that a SearchHandler can accept, the following query parameters can be passed to the MultiSearchHandler** * * *Query parameter that can be used both as common & specific to each individual query* threshold - The minimum number of matches(numFound) for a query. Default value is -1 . *Query parameter common to all the sub queries* count - Count of the queries in the url . This parameter is mandatory skiponfailure - Boolean parameter that specifies whether or not to include the results of queries whose numFound is less than threshold. This parameter is optional. stoponpass - Boolean parameter that specifies whether or not to stop executing if the query if first subquery has result count greater than the threshold. This parameter is optional. Thanks, Karthick