OK got it. Yes, sharing an index over NFS requires your own
DeletionPolicy.
So presumably you have readers on different machines accessing the
index over NFS, and then one machine that does the writing to that
index? How so you plan to get which commit point each of these
readers is
No, I have multiple readers in the same VM. I track open readers within my VM
and save those reader's commit points until the readers are gone.
--tim
- Michael McCandless [EMAIL PROTECTED] wrote:
OK got it. Yes, sharing an index over NFS requires your own
DeletionPolicy.
So
Oh then I don't think you need a custom deletion policy.
A single NFS client emulates delete-on-last-close semantics. Ie, if
the deletion of the file, and the held-open file handles, happen
through a single NFS client, then it emulates delete-on-last-close
semantics for you, by creating
Ha, you know it never occurred to me that the driver might do this for
me...I'll test it out. Thanks,
--tim
- Michael McCandless [EMAIL PROTECTED] wrote:
Oh then I don't think you need a custom deletion policy.
A single NFS client emulates delete-on-last-close semantics. Ie, if
The bigger picture here is NFS-safety. When I run a search, I hand off the
search results to another thread so that they can be processed as necessary --
in particular so that they can be JOINed with a SQL DB -- but I don't want to
completely lock the index from writes while doing a bunch of
Unfortunately, there is currently no way to ask an IndexReader
(DirectoryIndexReader) which commit point it's using.
I think it makes sense to add this. I'll open a Jira issue.
More answers below:
Tim Brennan wrote:
Is there a direct way to ask an IndexReader what segment it is
pointing
Is there a direct way to ask an IndexReader what segment it is pointing at?
That would make implementing custom deletion policies a LOT easier.
It seems like it should be pretty simple -- keep a list of open IndexReaders,
track what Segment files they're pointing to, and in onCommit don't