We could - not a huge fan of static factory methods myself though. And moving from the constructors to that would be challenging, wouldnt it (not internally, but if users are using it - I don't actually know enough about Solr's back compat commitment - just that its less than Lucene's)?

I think I'd prefer just moving back to delegation. It wasn't even so bad before, we just didn't need it and it dropped some code, so it appeared nice to switch. But now mix in SolrIndexReader and the new filter/query skipping and its not so nice. Doesnt really seem worth fighting for it to me anymore.

- Mark

Yonik Seeley wrote:
Perhaps we should use a factory method on SolrIndexSearcher (that way
we can wrap the reader and pass that to the SolrIndexSearcher
constructor?)

-Yonik

On Mon, May 25, 2009 at 1:24 PM, Mark Miller <[email protected]> wrote:
Yonik Seeley wrote:
On Mon, May 25, 2009 at 12:35 PM, Peter Wolanin
<[email protected]> wrote:

Playing with this last night, the error seems to occur for me only
with an index created using a solr build from a couple weeks ago
that's opened with a new solr build.  The error goes away if I issue a
delete query for *:* and re-index the content.

That's really strange... that really shouldn't be the case.  Perhaps
reopen() is acting a little different with the older index?
Please keep that index around if possible so we can get to the bottom of
this!

Mark - could it be the changes from delegation to inheritance for
SolrIndexSearcher?
super(reader) is called before we get a chance to to wrap the reader
and make it a SolrIndexReader...

-Yonik
http://www.lucidimagination.com

It could be. Good point - SolrIndexSearcher gets the plain reader and it
used to get SolrIndexReader. My fault, because I did most of the thinking on
that pre SolrIndexReader patch. So I guess, Lucene would feed the Solr
DocSet a regular reader instead of SolrIndexReader - no good. But, what I
still don't understand is how that plays into Peter's comment above and my
inability to easily replicate the problem. I'll keep digging, but it sounds
like I may just revert back to delegation or override getIndexReader to
return the SolrIndexReader - if thats done, we should prob deprecate
getReader. We'd obviously like to fully understand whats happening in any
case though. Until I can tickle the error, I can only guess myself.

- Mark


--
- Mark

http://www.lucidimagination.com






--
- Mark

http://www.lucidimagination.com



Reply via email to