Not sure if I'm doi9ng something wrong, or there is a bug somewhere but:
I was trying to create a test index of a lot every second in a year and try
query it (doesn't have to be time, I'm using it to explain the problem).
Example document consists of 7 fields:
document.add(new IntPoint("year", y
I think there is a bug in your collector, because the "int doc" that is
passed to the collect method is per-segment, but you are passing it to the
top-level reader.
You should override the setNextReader method in Collector, and hold onto
the "int docBase" that's passed in that LeafReaderContext, t
You can use LatLonPoint.newDistanceQuery to get the results within the
specified distance, and then use LatLonDocValuesField.newDistanceSort to
sort by distance, and use the IndexSearcher.search method that takes Sort.
Then the results should be all points within the radius, sorted by
distance. Th