"NRT reader "simply" lets you search the full index, including un-committed changes."
I am not sure I understand: I think the context of the discussion is for when the indexer crashes before IW.commit. At which point, does not really matter if you are using NRT, e.g. IW.getReader, or IndexReader.open, the uncommitted changes are NOT searchable. -John On Wed, Jan 13, 2010 at 2:20 AM, Michael McCandless < luc...@mikemccandless.com> wrote: > On Tue, Jan 12, 2010 at 6:10 PM, jchang <jchangkihat...@gmail.com> wrote: > > > Does anybody know how this works out with service restarts (both orderly > > shutdown and a crash)? If the service goes down while indexed items are > in > > RAMDir but not on disk, are they lost? Or is there some kind of log > > recovery? > > Lucene exposes commit() for exactly this reason -- on ungraceful > shutdown (ie, you didn't succeed in calling IndexWriter.close), the > index will be at the last successful commit() (or close(), which calls > commit internally). As with Zoie, it's still the app's job to replay > updates after the last commit. > > Note this is fully orthogonal to whether you use an NRT reader or not. > > NRT reader "simply" lets you search the full index, including > un-committed changes. > > Mike > > --------------------------------------------------------------------- > To unsubscribe, e-mail: java-dev-unsubscr...@lucene.apache.org > For additional commands, e-mail: java-dev-h...@lucene.apache.org > >