On 5/30/2014 12:25 PM, drmangrum wrote:
> -Running a 2 shard (each with a replica) setup with 100k records on JBoss7.
> -Using SolrJ and CloudSolrServer to interface with SOLR.
>
> Executing queries through the admin screen query tool is amazingly fast,
> usually less than 40ms.  However, when I execute the queries through my java
> application I get wildly inconsistent response times, anywhere from 190ms to
> 21 seconds.
>
> I've tried tweaking the searcher autowarming and cache settings within
> solrconfig, but nothing seems to make a dent.

One possibility is that you're not sending identical queries via SolrJ
and the admin interface.  Perhaps the SolrJ queries are a lot more
complex.  If you look at your Solr log (not the logging tab in the admin
UI), you can compare the exact queries that Solr is getting.  The
logging will need to be configured with a typical default logging level
of INFO (or greater).  Here's an example of one of those log lines:

INFO  - 2014-05-30 11:23:00.671; org.apache.solr.core.SolrCore;
[ai-main] webapp
=/solr path=/ncdismax
params={sort=registered_date+desc&start=0&q=*:*&wt=javabin
&qt=/ncdismax&fq={!edismax}customer_id:(SPU4051611970M+OR+SPU4051611858M+OR+SPU4051
002782M+OR+SPU4051002672M+OR+SPU4050809937M+OR+SPU4050809827M)&fq=&version=2&row
s=200} hits=6 status=0 QTime=339

The rows and start parameters can make a major difference in the total
elapsed time for a query, especially on a sharded index.

Thanks,
Shawn

Reply via email to