diff --git a/src/solrj/org/apache/solr/client/solrj/impl/LBHttpSolrServer.java b/src/solrj/org/apache/solr/client/solrj/impl/LBHttpSolrServer.java index 5b3e26adb5e..6d1c8985157 100644 --- a/src/solrj/org/apache/solr/client/solrj/impl/LBHttpSolrServer.java +++ b/src/solrj/org/apache/solr/client/solrj/impl/LBHttpSolrServer.java @@ -286,7 +286,7 @@ public class LBHttpSolrServer extends SolrServer { aliveCheckExecutor = Executors.newSingleThreadScheduledExecutor(); aliveCheckExecutor.scheduleAtFixedRate( getAliveCheckRunner(new WeakReference(this)), - this.interval, this.interval, TimeUnit.SECONDS); + this.interval, this.interval, TimeUnit.MILLISECONDS); } } } diff --git a/src/test/org/apache/solr/client/solrj/TestLBHttpSolrServer.java b/src/test/org/apache/solr/client/solrj/TestLBHttpSolrServer.java index a5730537158..dd40267c8ce 100644 --- a/src/test/org/apache/solr/client/solrj/TestLBHttpSolrServer.java +++ b/src/test/org/apache/solr/client/solrj/TestLBHttpSolrServer.java @@ -83,7 +83,7 @@ public class TestLBHttpSolrServer extends TestCase { s[i] = solr[i].getUrl(); } LBHttpSolrServer lbHttpSolrServer = new LBHttpSolrServer(httpClient, s); - lbHttpSolrServer.setAliveCheckInterval(1); + lbHttpSolrServer.setAliveCheckInterval(1000); SolrQuery solrQuery = new SolrQuery("*:*"); Set names = new HashSet(); QueryResponse resp = null; @@ -121,7 +121,7 @@ public class TestLBHttpSolrServer extends TestCase { public void testTwoServers() throws Exception { LBHttpSolrServer lbHttpSolrServer = new LBHttpSolrServer(httpClient, solr[0].getUrl(), solr[1].getUrl()); - lbHttpSolrServer.setAliveCheckInterval(1); + lbHttpSolrServer.setAliveCheckInterval(1000); SolrQuery solrQuery = new SolrQuery("*:*"); Set names = new HashSet(); QueryResponse resp = null;