Some more information.... I am currently doing the following:
SolrQuery query = new SolrQuery(); query.setQuery(test"); query.setParam("distrib", true); query.setFacet(true); query.setParam(FacetParams.FACET_RANGE, "dateTime"); query.setParam("f.dateTime." + FacetParams.FACET_RANGE_GAP, "+1MONTH"); query.setParam("f.dateTime." + FacetParams.FACET_RANGE_START, "2011-06-01T00:00:00Z-1YEAR"); query.setParam("f.dateTime." + FacetParams.FACET_RANGE_END, "2011-07-01T00:00:00Z"); query.setParam("f.dateTime." + FacetParams.FACET_MINCOUNT, "1"); System.out.println(query); int failure = 0; for(int x = 0; x < 1000; x ++){ QueryResponse response = mainServer.query(query); List<RangeFacet> ranges = response.getFacetRanges(); for(RangeFacet range : ranges){ if("dateTime".equals(range.getName())){ if(range.getCounts().size() == 0){ failure ++; } } } } System.out.println("Failed: " + failure); After this has run I get anywhere 30 - 40% failures (300 - 400). If I set distrib to false or take off the query it works fine. Any insight would be greatly appreciated. On Tue, Jun 7, 2011 at 2:27 PM, Jamie Johnson <jej2...@gmail.com> wrote: > I have a solr cloud setup wtih 2 servers, when executing a query against > them of the form: > > > http://localhost:8983/solr/select/?distrib=true&q=*:*&facet=true&facet.mincount=1&facet.range=dateTime&f.dateTime.facet.range.gap=%2B1MONTH&f.dateTime.facet.range.start=2011-06-01T00%3A00%3A00Z-1YEAR&f.dateTime.facet.range.end=2011-07-01T00%3A00%3A00Z&f.dateTime.facet.mincount=1&start=0&rows=0 > > I am seeing that sometimes the date facet has a count, and other times it > does not. Specifically I am seeing sometimes: > > <lst name="facet_ranges"> > <lst name="dateTime"> > <lst name="counts"/> > <str name="gap">+1MONTH</str> > <date name="start">2010-06-01T00:00:00Z</date> > <date name="end">2011-07-01T00:00:00Z</date> > </lst> > </lst> > > and others > <lst name="facet_ranges"> > <lst name="dateTime"> > <lst name="counts"> > <int name="2011-06-01T00:00:00Z">250</int> > </lst> > <str name="gap">+1MONTH</str> > <date name="start">2010-06-01T00:00:00Z</date> > <date name="end">2011-07-01T00:00:00Z</date> > </lst> > </lst> > > What could be causing this inconsistency? >