You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-dev@lucene.apache.org by Andrzej Bialecki <ab...@getopt.org> on 2009/12/22 14:02:25 UTC

Distributed search test using only one shard?

Hi,

I'm reading the source of BaseDistributedSearchTestCase, with this method:

   public void testDistribSearch() throws Exception {
     for (int nServers = 1; nServers < 2; nServers++) {
       createServers(nServers);
       RandVal.uniqueValues = new HashSet(); //reset random values
       doTest();
       destroyServers();
     }
   }

In the only test case that uses this abstract class, 
TestDistributedSearch, this method is not overridden, so if I'm reading 
it right we never really test distributed search with nServers > 1.

IMHO we should use at least 2 servers, otherwise this test doesn't make 
sense.

-- 
Best regards,
Andrzej Bialecki     <><
  ___. ___ ___ ___ _ _   __________________________________
[__ || __|__/|__||\/|  Information Retrieval, Semantic Web
___|||__||  \|  ||  |  Embedded Unix, System Integration
http://www.sigram.com  Contact: info at sigram dot com


Re: Distributed search test using only one shard?

Posted by Shalin Shekhar Mangar <sh...@gmail.com>.
On Tue, Dec 22, 2009 at 8:23 PM, Yonik Seeley <yo...@lucidimagination.com>wrote:

> Looks like the recently committed SOLR-1608 accidentally changed
> this... it was "nservers<4" before that.
>
>
Yes, I changed it for debugging and then forgot to change it back. Sorry
about that.

-- 
Regards,
Shalin Shekhar Mangar.

Re: Distributed search test using only one shard?

Posted by Yonik Seeley <yo...@lucidimagination.com>.
Looks like the recently committed SOLR-1608 accidentally changed
this... it was "nservers<4" before that.

-Yonik
http://www.lucidimagination.com


On Tue, Dec 22, 2009 at 8:02 AM, Andrzej Bialecki <ab...@getopt.org> wrote:
> Hi,
>
> I'm reading the source of BaseDistributedSearchTestCase, with this method:
>
>  public void testDistribSearch() throws Exception {
>    for (int nServers = 1; nServers < 2; nServers++) {
>      createServers(nServers);
>      RandVal.uniqueValues = new HashSet(); //reset random values
>      doTest();
>      destroyServers();
>    }
>  }
>
> In the only test case that uses this abstract class, TestDistributedSearch,
> this method is not overridden, so if I'm reading it right we never really
> test distributed search with nServers > 1.
>
> IMHO we should use at least 2 servers, otherwise this test doesn't make
> sense.
>
> --
> Best regards,
> Andrzej Bialecki     <><
>  ___. ___ ___ ___ _ _   __________________________________
> [__ || __|__/|__||\/|  Information Retrieval, Semantic Web
> ___|||__||  \|  ||  |  Embedded Unix, System Integration
> http://www.sigram.com  Contact: info at sigram dot com
>
>