How big is the index (document count, gigabytes)? How much RAM is on the servers?
How big is your Java heap? How are the servers hosted? AWS? Long queries are often caused by long-tail queries fetched from disk. There are several ways to speed these up, but they all use RAM or SSD. wunder Walter Underwood wun...@wunderwood.org http://observer.wunderwood.org/ On Nov 27, 2014, at 12:56 PM, solr-user <solr-u...@hotmail.com> wrote: > I inherited a set of some old 1.4x Solrs running under tomcat6/java6 > > while I will eventually upgrade them to a more recent solr/tomcat/java, I am > unable to do in near term > > one of my priority fixes tho is to implement some sort of timeout for solr > queries that exceed 1000ms (or so); ie if the query takes longer than that, > I want to abort that query (returning nothing or an error or whatever) so > that solr can process other queries. while we have optimized our queries > for an average 50ms response time, we do occasionally see some that can run > between 10 and 100 seconds. > > I know that this version of Solr itself doesn't have a built in timeout > mechanism, which leaves me with figuring out what to do (it seems to me that > I have to figure out how to get Tomcat to timeout the queries somehow) > > note that I DID google until my fingers hurt and have not been able to find > clear (at least not clear to me) instructions on how do to so > > Details: > > 1. the setup uses the DataImportHandler to updates Solr, and updates occur > often and can be quite large; we use batchSize="10000" and autoCommit="true" > with doc size being around 1400 to 1600 bytes. I dont want the timeout to > kill the imports of course > > 2. I tried adding a timeout param to the tomcat configuration but it doesnt > work: <Connector port="8086" protocol="HTTP/1.1" > connectionTimeout="20000" protocol="HTTP/1.1" > timeout="1" /> > > any thoughts?? can anyone point me in the right direction on how to > implement this? > > any help appreciated. thx in advance > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/confused-about-how-to-set-a-solr-query-timeout-when-using-tomcat-tp4171363.html > Sent from the Solr - User mailing list archive at Nabble.com.