Thanks Noble - it is, I just didn't remember I had flagged it before. I was running tests while my comp was under a bit of strain and watched it fail a couple times, so I just through in a pause and retry so it had enough time to start the second server - looking at the exception from SOLR-1161, it does appear to be the same issue. I think we can resolve it.

- Mark

Noble Paul നോബിള്‍ नोब्ळ् wrote:
hi Mark ,
it it a fix  for SOLR-1161 ?



On Mon, Jun 8, 2009 at 8:17 PM, <[email protected]> wrote:
Author: markrmiller
Date: Mon Jun  8 14:47:40 2009
New Revision: 782658

URL: http://svn.apache.org/viewvc?rev=782658&view=rev
Log:
add extra pause and retry for test that fails on slower comp

Modified:
   
lucene/solr/trunk/src/test/org/apache/solr/client/solrj/TestLBHttpSolrServer.java

Modified: 
lucene/solr/trunk/src/test/org/apache/solr/client/solrj/TestLBHttpSolrServer.java
URL: 
http://svn.apache.org/viewvc/lucene/solr/trunk/src/test/org/apache/solr/client/solrj/TestLBHttpSolrServer.java?rev=782658&r1=782657&r2=782658&view=diff
==============================================================================
--- 
lucene/solr/trunk/src/test/org/apache/solr/client/solrj/TestLBHttpSolrServer.java
 (original)
+++ 
lucene/solr/trunk/src/test/org/apache/solr/client/solrj/TestLBHttpSolrServer.java
 Mon Jun  8 14:47:40 2009
@@ -137,7 +137,13 @@
    solr[1].jetty = null;
    solr[0].startJetty();
    Thread.sleep(1200);
-    resp = lbHttpSolrServer.query(solrQuery);
+    try {
+      resp = lbHttpSolrServer.query(solrQuery);
+    } catch(SolrServerException e) {
+      // try again after a pause in case the error is lack of time to start 
server
+      Thread.sleep(3000);
+      resp = lbHttpSolrServer.query(solrQuery);
+    }
    name = resp.getResults().get(0).getFieldValue("name").toString();
    Assert.assertEquals("solr0", name);
  }








--
- Mark

http://www.lucidimagination.com



Reply via email to