The unexpected behavior no longer occurs after switching to the new Lucene release candidate. -Lex
>From: "Armbrust, Daniel C." <[EMAIL PROTECTED]> >Reply-To: "Lucene Users List" <[EMAIL PROTECTED]> >To: 'Lucene Users List' <[EMAIL PROTECTED]> >Subject: RE: Merging (adding) indices >Date: Tue, 28 May 2002 07:51:55 -0500 > >I have also had the indexes that I merged disappear when I was merging >indexes. It seems to happen nearly 100% of the time, when merging more >than >2 indexes. I just thought it was the normal behavior. However, when I >merge only 2 indexes, they usually don't get deleted. I don't have any >code >that deletes the indexes on mergeing. Maybe I should look closer at some >code if this isn't supposed to be happening? > >Dan > > > > > >-----Original Message----- >From: Otis Gospodnetic [mailto:[EMAIL PROTECTED]] >Sent: Monday, May 27, 2002 5:41 PM >To: Lucene Users List >Subject: Re: Merging (adding) indices > > >The source code looks like this: > > public final synchronized void addIndexes(Directory[] dirs) > throws IOException { > optimize(); // start with zero or >1 seg > for (int i = 0; i < dirs.length; i++) { > SegmentInfos sis = new SegmentInfos(); // read infos from >dir > sis.read(dirs[i]); > for (int j = 0; j < sis.size(); j++) { > segmentInfos.addElement(sis.info(j)); // add each info > } > } > optimize(); // final cleanup > } > >So I think the original directories/indices should not be modified in >any way. Are you sure your application is not deleting them? > >Otis > > > >--- Lex Lawrence <[EMAIL PROTECTED]> wrote: > > Hello- > > I am using org.apache.lucene.index.IndexWriter.addIndexes(Directory[] > > dirs) > > to merge several indices into one. The resulting index appears to > > work > > fine, but afterward the original indices seem to have been completely > > > > emptied. > > > > I can deal with that, but I just wanted to check: Is this method > > supposed to > > alter the indices in the 'dirs' parameter? It's not mentioned in the > > > > javadoc. > > > > Thanks- Lex > > > > _________________________________________________________________ > > Chat with friends online, try MSN Messenger: http://messenger.msn.com > > > > > > -- > > To unsubscribe, e-mail: > > <mailto:[EMAIL PROTECTED]> > > For additional commands, e-mail: > > <mailto:[EMAIL PROTECTED]> > > > > >__________________________________________________ >Do You Yahoo!? >Yahoo! - Official partner of 2002 FIFA World Cup >http://fifaworldcup.yahoo.com > >-- >To unsubscribe, e-mail: ><mailto:[EMAIL PROTECTED]> >For additional commands, e-mail: ><mailto:[EMAIL PROTECTED]> > >-- >To unsubscribe, e-mail: ><mailto:[EMAIL PROTECTED]> >For additional commands, e-mail: ><mailto:[EMAIL PROTECTED]> > _________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
