Hi, I think you mentioned 225GB of data somewhere. You can open IndexReaders "on demand", but that's not a cheap operation, esp. not with so much data. You want to keep your IndexReaders opened for a while. Multiple requests/threads can share them.
Otis -- Sematext -- http://sematext.com/ -- Lucene - Solr - Nutch ----- Original Message ---- > From: Sebastin <[EMAIL PROTECTED]> > To: java-user@lucene.apache.org > Sent: Friday, June 20, 2008 2:46:32 AM > Subject: Re: creating Array of IndexReaders > > > Hi otis, > > Rightnow I am using Multi Reader by just collecting array of indexReaders > > IndexReader[] readArray = > { indexIR1, indexIR2, indexIR3, indexIR4}; > > > > //merged reader > IndexReader mergedReader = new MultiReader(readArray); > > its not possible for me to create array of index readers based on the user > input? IndexReader > > > Otis Gospodnetic wrote: > > > > Hi, > > > > Have you looked at MultiReader? Opening IndexReaders like that will cost > > you... > > > > > > Otis > > -- > > Sematext -- http://sematext.com/ -- Lucene - Solr - Nutch > > > > > > ----- Original Message ---- > >> From: Sebastin > >> To: java-user@lucene.apache.org > >> Sent: Friday, June 20, 2008 2:04:12 AM > >> Subject: creating Array of IndexReaders > >> > >> > >> Hi All, > >> > >> > >> I need to create dynamic Index Readers based on the user input. > >> > >> for example > >> > >> if the user needs to see the records from june 17-june 20 > >> > >> > >> Directory indexFsDir1 = > >> FSDirectory.getDirectory("C:\\200806\\17\\outgoing1", false); > >> IndexReader indexIR1 = IndexReader.open(indexFsDir1); > >> > >> Directory indexFsDir1 = > >> FSDirectory.getDirectory("C:\\200806\\18\\outgoing1", false); > >> IndexReader indexIR2 = IndexReader.open(indexFsDir1); > >> > >> Directory indexFsDir1 = > >> FSDirectory.getDirectory("C:\\200806\\19\\outgoing1", false); > >> IndexReader indexIR3 = IndexReader.open(indexFsDir1); > >> > >> Directory indexFsDir1 = > >> FSDirectory.getDirectory("C:\\200806\\20\\outgoing1", false); > >> IndexReader indexIR4 = IndexReader.open(indexFsDir1); > >> > >> > >> IndexReader[] readArray = > >> { indexIR1, indexIR2, indexIR3, indexIR4}; > >> > >> > >> > >> //merged reader > >> IndexReader mergedReader = new MultiReader(readArray); > >> > >> IndexSearcher is = new IndexSearcher(mergedReader); > >> > >> likewise is there any possibility to create Array of Index Readers. > >> > >> > >> -- > >> View this message in context: > >> http://www.nabble.com/creating-Array-of-IndexReaders-tp18023594p18023594.html > >> Sent from the Lucene - Java Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]