> Hi folks. > > I'm new to Lucene so this may be an obvious questions, but I am having > problems with Lucene 1.3-rc2. I've got a bit of code which looks something > like this.... > > public static void getSearchResults(String searchString, String indexDir) > { > try > { > Searcher searcher = new IndexSearcher(indexDir); > ..... > etc... > ..... > } > catch (Exception ex) > { > } > } > > I'm calling it to from a web application (servlet) running in tomcat in > conjunction with struts and velocity. If I use the Lucene 1.2 binary > release, it all works fine and I get the search results ok. However, when > I replace the 1.2 jar file with the 1.3-rc2 jat file, (leaving all of my > code exactly the same) it stops working, and I get a path not found > exception being thrown. > > I've narrowed it down to the IndexReader.open(final Directory directory) > method. Even if I pass a valid Directory object into this (created by > FSDirectory), it just seems to throw the exception, (even though I know > the directory object is not null etc). The bizarre thing is that this > problem only seems to occur when I run it from the web application. If I > invoke the same code from the command line, it works ok, (even though I'm > using the same string for the index dir). > > Anyone got any ideas? (I want to use 1.3 because I want to exploit some of > the newer features). Does running from within a web application do > something strange with the paths, even though the strings I'm using are > fully qualified? > > Thanks for your help, > > Iain Young > http://www.microfocus.com >
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]