Correct - changing SegmentReader would be best, but in the past, getting
proposed patches included has been slower than expected. So, by making the
SegmentReader more easily subclassed (which should hopefully get approved
quicker), I can still have a "build" of Lucene that does not require
patching any files. (just including classes in the appropriate package to
access package level vars/methods).

I can do everything needed (without subclassing) if there was a
package/public accessor to the segment "name".

-----Original Message-----
From: Doug Cutting [mailto:[EMAIL PROTECTED]
Sent: Monday, May 01, 2006 5:44 PM
To: java-dev@lucene.apache.org
Subject: Re: SegmentReader changes?


Robert Engels wrote:
> In implementing the 'reopen()' method SegmentReader needs to be subclassed
> in order to support 'refreshing' the deleted documents.

Why subclass?  Why not simply change SegmentReader?  It's not a public
class at present, and making it a public class would be a bigger change
than should be required to implement reopen.

But perhaps I just don't yet understand how you intend to implement
re-open.  I think I'd implement it as something that inquired whether
the deletions have changed, and if they have, clone the SegmentReader,
re-opening all files, but only re-reading the deletions.

Doug

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to