I trying to split the query into multiple subqueries (LocalSolrQueryRequest) in my custom handler and call SearchHandler's handleRequestBody on each of these LocalSolrQueryRequests. Its sort of a query chaining. I am planning to just run a search using queryComponent. I will have a threshold parameter. The first query that passes that threshold could be returned. Its a lot more flexible than that but I am just talking about its implementation perspective. In terms of implementation, does that sound ok?
P.S: I am trying to implement something along this lines.. https://issues.apache.org/jira/browse/SOLR-1093.. Instead of processing them in batch, I am running one by one and its sort of a query chaining. On Wed, Jul 18, 2012 at 4:18 PM, Karthick Duraisamy Soundararaj < d.s.karth...@gmail.com> wrote: > Spot on! Thank Mark.. > > > On Wed, Jul 18, 2012 at 4:01 PM, Mark Miller <markrmil...@gmail.com>wrote: > >> I'd guess the getSearcher call you are making is incrementing the ref >> count and you are not decrementing it? >> >> On Jul 18, 2012, at 12:17 PM, Karthick Duraisamy Soundararaj wrote: >> >> > Hi All, >> > The SolrCore seems to have a reference counted searcher with >> it. I had to write a customSearchHandler that extends SearchHandler, and I >> was playing around with it. I did the following change to search handler >> > >> > SearchHanlder.java >> > -------------------------- >> > handleRequestBody(SolrQueryRequest req,SolrQueryResponse req) >> > { >> > System.out.println("Reference count Before Search:" >> +req.getCore().getSearcher.getRefcount) //In eclipse .. >> > .................. >> > ........... >> > System.out.println("Reference count After Search :" >> +req.getCore().getSearcher.getRefcount) // In eclipse >> > } >> > >> > >> > Now, I am surprised to see Reference count not getting decremented at >> all. Following is the sample output I get >> > >> > Reference count before search:1 >> > Reference count after search:2 >> > .............................................. >> > Reference count before search:2 >> > Reference count after search:3 >> > ............................................. >> > Reference count before search:4 >> > Reference count after search:5 >> > ... >> > .... >> > Reference count before search:3000 >> > Reference count after search:30001 >> > >> > >> > The reference count seems to be increasing. Wouldnt this cause a memory >> leak? >> > >> > >> > >> > >> > >> > >> >> - Mark Miller >> lucidimagination.com >> >> >> >> >> >> >> >> >> >> >> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org >> For additional commands, e-mail: dev-h...@lucene.apache.org >> >> > > >