Well... you can use oal.index.IndexFileNameFilter.getFilter() to filter for only the Lucene index files, or, you could filter for the additional files you know you've placed in the index directory?
The motivation for this change was that Directory is the wrong place to have "smarts" about what is & isn't an index file: it's too low-level (and, different Directory impls were inconsistent). Especially with flexible indexing coming, where a codec can write whatever files it wants, the Directory has no way know. Some details are in http://issues.apache.org/jira/browse/LUCENE-1468. Mike On Fri, Nov 6, 2009 at 12:39 AM, Daniel Noll <dan...@nuix.com> wrote: > Hi all. > > I am trying to clean up some deprecated calls which are showing up on > upgrading to 2.9.0 (from 2.3.2...), and I have just come across > Directory.list(), which says this: > >> Deprecated For some Directory implementations (FSDirectory, and its >> subclasses), this method silently filters its results to include only index >> files. Please use listAll instead, which does no filtering. > > * We have files in there which aren't Lucene's so obviously > listAll() will not work. > * We can't use FSDirectory directly because our tests rely on the > Directory abstraction so that they can use a RAMDirectory. > > Given this, what is the suggested replacement for this method once it goes > away? > > I'm not sure I understand the motivation for the change in list(), but > I do think it was inconsistent for Directory implementations to > perform different filtering (they should have at least all used the > same filter.) > > Daniel > > -- > Daniel Noll Forensic and eDiscovery Software > Senior Developer The world's most advanced > Nuix email data analysis > http://nuix.com/ and eDiscovery software > > --------------------------------------------------------------------- > To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org > For additional commands, e-mail: java-user-h...@lucene.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org For additional commands, e-mail: java-user-h...@lucene.apache.org