Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Lucene: Java-User

SearchFiles demo fails with exception while IndexFiles works

 

 

Lucene java-user RSS feed   Index | Next | Previous | View Threaded


s.rajan09 at gmail

Oct 27, 2009, 5:34 PM

Post #1 of 3 (513 views)
Permalink
SearchFiles demo fails with exception while IndexFiles works

hi, I am playing with lucene 2.9.0 source build, ant 1.7.1, jdk1.6.0, win XP
home edition.
I dont have clover or jFlex installed.
I built the srcs and ran IndexFiles demo and that worked. However when I run
SearchFiles
I have an exception that says:
Exception in thread "main" java.lang.Error: Unresolved compilation problems:
The field directory is defined in an inherited type and an enclosing
sco
pe
The field directory is defined in an inherited type and an enclosing
sco
pe
The field directory is defined in an inherited type and an enclosing
sco
pe
at
org.apache.lucene.index.DirectoryReader.open(DirectoryReader.java:71)
----------------------------------------
I run the build again and its the same thing.
Is there anything else I need to do?

tks,
-rajan


lucene at mikemccandless

Oct 28, 2009, 2:35 AM

Post #2 of 3 (460 views)
Permalink
Re: SearchFiles demo fails with exception while IndexFiles works [In reply to]

Are you using an IDE (Eclipse)? This may help?:

http://forums.java.net/jive/thread.jspa?messageID=363989

Or maybe try building from the command line instead ("ant compile-demo")?

Mike

On Tue, Oct 27, 2009 at 8:34 PM, s rajan <s.rajan09 [at] gmail> wrote:
> hi, I am playing with lucene 2.9.0 source build, ant 1.7.1, jdk1.6.0, win XP
> home edition.
> I dont have clover or jFlex installed.
> I built the srcs and ran IndexFiles demo and that worked. However when I run
> SearchFiles
> I have an exception that says:
> Exception in thread "main" java.lang.Error: Unresolved compilation problems:
>        The field directory is defined in an inherited type and an enclosing
> sco
> pe
>        The field directory is defined in an inherited type and an enclosing
> sco
> pe
>        The field directory is defined in an inherited type and an enclosing
> sco
> pe
>        at
> org.apache.lucene.index.DirectoryReader.open(DirectoryReader.java:71)
> ----------------------------------------
> I run the build again and its the same thing.
> Is there anything else I need to do?
>
> tks,
> -rajan
>

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe [at] lucene
For additional commands, e-mail: java-user-help [at] lucene


s.rajan09 at gmail

Oct 28, 2009, 10:04 PM

Post #3 of 3 (455 views)
Permalink
Re: SearchFiles demo fails with exception while IndexFiles works [In reply to]

Mike, thanks for that URL, I saw a similar issue being discussed on
stackoverflow.

I am doing an external ant build and trying to debug through eclipse. For
some reason eclipse is failing to import the ant build file as a project so
i use a debug configuration and build externally.

I now have the problem solved by a clean build but my hunch is that the jar
had 1.4 and 1.6 object files -for a brief period I had a few sources build
via eclipse and it had a jdk1.4 as its setting.
I still have the 'bad' jar but have not investigated further - the only
thing I can think of is object file mismatch.
It beats me why the loader flags compilation error or perhaps does it means
JIT compilation? I think there is an issue here in that the jar creation
should have failed or the loader should have reported a version mismatch.

On Wed, Oct 28, 2009 at 3:05 PM, Michael McCandless <
lucene [at] mikemccandless> wrote:

> Are you using an IDE (Eclipse)? This may help?:
>
> http://forums.java.net/jive/thread.jspa?messageID=363989
>
> Or maybe try building from the command line instead ("ant compile-demo")?
>
> Mike
>
> On Tue, Oct 27, 2009 at 8:34 PM, s rajan <s.rajan09 [at] gmail> wrote:
> > hi, I am playing with lucene 2.9.0 source build, ant 1.7.1, jdk1.6.0, win
> XP
> > home edition.
> > I dont have clover or jFlex installed.
> > I built the srcs and ran IndexFiles demo and that worked. However when I
> run
> > SearchFiles
> > I have an exception that says:
> > Exception in thread "main" java.lang.Error: Unresolved compilation
> problems:
> > The field directory is defined in an inherited type and an
> enclosing
> > sco
> > pe
> > The field directory is defined in an inherited type and an
> enclosing
> > sco
> > pe
> > The field directory is defined in an inherited type and an
> enclosing
> > sco
> > pe
> > at
> > org.apache.lucene.index.DirectoryReader.open(DirectoryReader.java:71)
> > ----------------------------------------
> > I run the build again and its the same thing.
> > Is there anything else I need to do?
> >
> > tks,
> > -rajan
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe [at] lucene
> For additional commands, e-mail: java-user-help [at] lucene
>
>

Lucene java-user RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.