You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cxf.apache.org by Benson Margulies <bi...@gmail.com> on 2008/10/02 03:29:35 UTC

Bizarre mvn error building on this Mac I just got

??????? This isn't in eclipse!

-------------------------------------------------------
 T E S T S
-------------------------------------------------------
Running org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.045 sec
<<< FAILURE!
testGeneration(org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest)
Time elapsed: 0.005 sec  <<< ERROR!
java.lang.Error: Unresolved compilation problems:
    The type java.net.URISyntaxException cannot be resolved. It is
indirectly referenced from required .class files
    The import java.io.File cannot be resolved
    The import java.io.FileInputStream cannot be resolved
    The hierarchy of the type WSDLToJavaScriptTest is inconsistent
    Exception cannot be resolved to a type
    The constructor JavaScriptContainer(ToolSpec) refers to the missing type
Exception
    String cannot be resolved to a type
    The method getLocation(String) from the type ProcessorTestBase refers to
the missing type String
    String cannot be resolved to a type
    File cannot be resolved to a type
    String cannot be resolved to a type
    String cannot be resolved to a type
    String cannot be resolved to a type
    File cannot be resolved to a type
    File cannot be resolved to a type
    File cannot be resolved to a type
    FileInputStream cannot be resolved to a type
    FileInputStream cannot be resolved to a type
    String cannot be resolved to a type

    at
org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest.<init>(WSDLToJavaScriptTest.java:1)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
    at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
    at
org.junit.internal.runners.JUnit4ClassRunner.createTest(JUnit4ClassRunner.java:72)
    at
org.junit.internal.runners.JUnit4ClassRunner.invokeTestMethod(JUnit4ClassRunner.java:79)
    at
org.junit.internal.runners.JUnit4ClassRunner.runMethods(JUnit4ClassRunner.java:51)
    at
org.junit.internal.runners.JUnit4ClassRunner$1.run(JUnit4ClassRunner.java:44)
    at
org.junit.internal.runners.ClassRoadie.runUnprotected(ClassRoadie.java:27)
    at
org.junit.internal.runners.ClassRoadie.runProtected(ClassRoadie.java:37)
    at
org.junit.internal.runners.JUnit4ClassRunner.run(JUnit4ClassRunner.java:42)
    at
org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62)
    at
org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:140)
    at
org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:127)
    at org.apache.maven.surefire.Surefire.run(Surefire.java:177)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at
org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:345)
    at
org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:1009)


Results :

Tests in error:

testGeneration(org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest)

Tests run: 1, Failures: 0, Errors: 1, Skipped: 0

Re: Bizarre mvn error building on this Mac I just got

Posted by Daniel Kulp <dk...@apache.org>.
If you type
mvn -version
it usually spits out the java version it has found.

Dan


On Friday 03 October 2008, Benson Margulies wrote:
> Hmm. How can I tell if mvn has, for some reason, decided to favor 1.6?
>
> On Fri, Oct 3, 2008 at 6:51 AM, David Bosschaert <da...@iona.com> 
wrote:
> > Hi Benson,
> >
> > FWIW - I got similar errors before and they seem to be caused in the
> > situation where you have two things compiling into the same location
> > using different versions of the JDK.
> >
> > In my case I had Eclipse projects for my maven modules (created
> > using mvn eclipse:eclipse) compiling into target/classes - the same
> > target directory as Maven uses. However my eclipse used Java 6 while
> > Maven was using Java 5. So my target/classes ended having a mixture
> > of Java 5 and Java 6 compiled .class files. Thats whenI got the
> > error.
> >
> > In my case closing Eclipse then doing a mvn clean fixed the
> > problem...
> >
> > Cheers,
> >
> > David
> > BTW this was on Windows.
> >
> > Benson Margulies wrote:
> >> ??????? This isn't in eclipse!
> >>
> >> -------------------------------------------------------
> >>  T E S T S
> >> -------------------------------------------------------
> >> Running org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest
> >> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed:
> >> 0.045 sec <<< FAILURE!
> >>
> >> testGeneration(org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScr
> >>iptTest) Time elapsed: 0.005 sec  <<< ERROR!
> >> java.lang.Error: Unresolved compilation problems:
> >>    The type java.net.URISyntaxException cannot be resolved. It is
> >> indirectly referenced from required .class files
> >>    The import java.io.File cannot be resolved
> >>    The import java.io.FileInputStream cannot be resolved
> >>    The hierarchy of the type WSDLToJavaScriptTest is inconsistent
> >>    Exception cannot be resolved to a type
> >>    The constructor JavaScriptContainer(ToolSpec) refers to the
> >> missing type
> >> Exception
> >>    String cannot be resolved to a type
> >>    The method getLocation(String) from the type ProcessorTestBase
> >> refers to
> >> the missing type String
> >>    String cannot be resolved to a type
> >>    File cannot be resolved to a type
> >>    String cannot be resolved to a type
> >>    String cannot be resolved to a type
> >>    String cannot be resolved to a type
> >>    File cannot be resolved to a type
> >>    File cannot be resolved to a type
> >>    File cannot be resolved to a type
> >>    FileInputStream cannot be resolved to a type
> >>    FileInputStream cannot be resolved to a type
> >>    String cannot be resolved to a type
> >>
> >>    at
> >>
> >> org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest.<init>(
> >>WSDLToJavaScriptTest.java:1) at
> >> sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
> >> Method)
> >>    at
> >>
> >> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstru
> >>ctorAccessorImpl.java:39) at
> >>
> >> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Delegatin
> >>gConstructorAccessorImpl.java:27) at
> >> java.lang.reflect.Constructor.newInstance(Constructor.java:494) at
> >>
> >> org.junit.internal.runners.JUnit4ClassRunner.createTest(JUnit4Class
> >>Runner.java:72) at
> >>
> >> org.junit.internal.runners.JUnit4ClassRunner.invokeTestMethod(JUnit
> >>4ClassRunner.java:79) at
> >>
> >> org.junit.internal.runners.JUnit4ClassRunner.runMethods(JUnit4Class
> >>Runner.java:51) at
> >>
> >> org.junit.internal.runners.JUnit4ClassRunner$1.run(JUnit4ClassRunne
> >>r.java:44) at
> >> org.junit.internal.runners.ClassRoadie.runUnprotected(ClassRoadie.j
> >>ava:27) at
> >> org.junit.internal.runners.ClassRoadie.runProtected(ClassRoadie.jav
> >>a:37) at
> >>
> >> org.junit.internal.runners.JUnit4ClassRunner.run(JUnit4ClassRunner.
> >>java:42) at
> >>
> >> org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSe
> >>t.java:62) at
> >>
> >> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeT
> >>estSet(AbstractDirectoryTestSuite.java:140) at
> >>
> >> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(
> >>AbstractDirectoryTestSuite.java:127) at
> >> org.apache.maven.surefire.Surefire.run(Surefire.java:177) at
> >> sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at
> >>
> >> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImp
> >>l.java:39) at
> >>
> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcc
> >>essorImpl.java:25) at
> >> java.lang.reflect.Method.invoke(Method.java:585)
> >>    at
> >>
> >> org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(
> >>SurefireBooter.java:345) at
> >>
> >> org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter
> >>.java:1009)
> >>
> >>
> >> Results :
> >>
> >> Tests in error:
> >>
> >>
> >> testGeneration(org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScr
> >>iptTest)
> >>
> >> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
> >
> > ----------------------------
> > IONA Technologies PLC (registered in Ireland)
> > Registered Number: 171387
> > Registered Address: The IONA Building, Shelbourne Road, Dublin 4,
> > Ireland



-- 
J. Daniel Kulp
dkulp@apache.org
http://www.dankulp.com/blog

Re: Bizarre mvn error building on this Mac I just got

Posted by Benson Margulies <bi...@gmail.com>.
Hmm. How can I tell if mvn has, for some reason, decided to favor 1.6?

On Fri, Oct 3, 2008 at 6:51 AM, David Bosschaert <da...@iona.com> wrote:

> Hi Benson,
>
> FWIW - I got similar errors before and they seem to be caused in the
> situation where you have two things compiling into the same location using
> different versions of the JDK.
>
> In my case I had Eclipse projects for my maven modules (created using mvn
> eclipse:eclipse) compiling into target/classes - the same target directory
> as Maven uses. However my eclipse used Java 6 while Maven was using Java 5.
> So my target/classes ended having a mixture of Java 5 and Java 6 compiled
> .class files. Thats whenI got the error.
>
> In my case closing Eclipse then doing a mvn clean fixed the problem...
>
> Cheers,
>
> David
> BTW this was on Windows.
>
>
> Benson Margulies wrote:
>
>> ??????? This isn't in eclipse!
>>
>> -------------------------------------------------------
>>  T E S T S
>> -------------------------------------------------------
>> Running org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest
>> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.045 sec
>> <<< FAILURE!
>>
>> testGeneration(org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest)
>> Time elapsed: 0.005 sec  <<< ERROR!
>> java.lang.Error: Unresolved compilation problems:
>>    The type java.net.URISyntaxException cannot be resolved. It is
>> indirectly referenced from required .class files
>>    The import java.io.File cannot be resolved
>>    The import java.io.FileInputStream cannot be resolved
>>    The hierarchy of the type WSDLToJavaScriptTest is inconsistent
>>    Exception cannot be resolved to a type
>>    The constructor JavaScriptContainer(ToolSpec) refers to the missing
>> type
>> Exception
>>    String cannot be resolved to a type
>>    The method getLocation(String) from the type ProcessorTestBase refers
>> to
>> the missing type String
>>    String cannot be resolved to a type
>>    File cannot be resolved to a type
>>    String cannot be resolved to a type
>>    String cannot be resolved to a type
>>    String cannot be resolved to a type
>>    File cannot be resolved to a type
>>    File cannot be resolved to a type
>>    File cannot be resolved to a type
>>    FileInputStream cannot be resolved to a type
>>    FileInputStream cannot be resolved to a type
>>    String cannot be resolved to a type
>>
>>    at
>>
>> org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest.<init>(WSDLToJavaScriptTest.java:1)
>>    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
>> Method)
>>    at
>>
>> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
>>    at
>>
>> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
>>    at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
>>    at
>>
>> org.junit.internal.runners.JUnit4ClassRunner.createTest(JUnit4ClassRunner.java:72)
>>    at
>>
>> org.junit.internal.runners.JUnit4ClassRunner.invokeTestMethod(JUnit4ClassRunner.java:79)
>>    at
>>
>> org.junit.internal.runners.JUnit4ClassRunner.runMethods(JUnit4ClassRunner.java:51)
>>    at
>>
>> org.junit.internal.runners.JUnit4ClassRunner$1.run(JUnit4ClassRunner.java:44)
>>    at
>> org.junit.internal.runners.ClassRoadie.runUnprotected(ClassRoadie.java:27)
>>    at
>> org.junit.internal.runners.ClassRoadie.runProtected(ClassRoadie.java:37)
>>    at
>>
>> org.junit.internal.runners.JUnit4ClassRunner.run(JUnit4ClassRunner.java:42)
>>    at
>>
>> org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62)
>>    at
>>
>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:140)
>>    at
>>
>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:127)
>>    at org.apache.maven.surefire.Surefire.run(Surefire.java:177)
>>    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>    at
>>
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>    at
>>
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>    at java.lang.reflect.Method.invoke(Method.java:585)
>>    at
>>
>> org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:345)
>>    at
>>
>> org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:1009)
>>
>>
>> Results :
>>
>> Tests in error:
>>
>>
>> testGeneration(org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest)
>>
>> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
>>
>>
>>
>
> ----------------------------
> IONA Technologies PLC (registered in Ireland)
> Registered Number: 171387
> Registered Address: The IONA Building, Shelbourne Road, Dublin 4, Ireland
>

Re: Bizarre mvn error building on this Mac I just got

Posted by David Bosschaert <da...@iona.com>.
Hi Benson,

FWIW - I got similar errors before and they seem to be caused in the 
situation where you have two things compiling into the same location 
using different versions of the JDK.

In my case I had Eclipse projects for my maven modules (created using 
mvn eclipse:eclipse) compiling into target/classes - the same target 
directory as Maven uses. However my eclipse used Java 6 while Maven was 
using Java 5.
So my target/classes ended having a mixture of Java 5 and Java 6 
compiled .class files. Thats whenI got the error.

In my case closing Eclipse then doing a mvn clean fixed the problem...

Cheers,

David
BTW this was on Windows.

Benson Margulies wrote:
> ??????? This isn't in eclipse!
>
> -------------------------------------------------------
>  T E S T S
> -------------------------------------------------------
> Running org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest
> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.045 sec
> <<< FAILURE!
> testGeneration(org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest)
> Time elapsed: 0.005 sec  <<< ERROR!
> java.lang.Error: Unresolved compilation problems:
>     The type java.net.URISyntaxException cannot be resolved. It is
> indirectly referenced from required .class files
>     The import java.io.File cannot be resolved
>     The import java.io.FileInputStream cannot be resolved
>     The hierarchy of the type WSDLToJavaScriptTest is inconsistent
>     Exception cannot be resolved to a type
>     The constructor JavaScriptContainer(ToolSpec) refers to the missing type
> Exception
>     String cannot be resolved to a type
>     The method getLocation(String) from the type ProcessorTestBase refers to
> the missing type String
>     String cannot be resolved to a type
>     File cannot be resolved to a type
>     String cannot be resolved to a type
>     String cannot be resolved to a type
>     String cannot be resolved to a type
>     File cannot be resolved to a type
>     File cannot be resolved to a type
>     File cannot be resolved to a type
>     FileInputStream cannot be resolved to a type
>     FileInputStream cannot be resolved to a type
>     String cannot be resolved to a type
>
>     at
> org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest.<init>(WSDLToJavaScriptTest.java:1)
>     at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
>     at
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
>     at
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
>     at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
>     at
> org.junit.internal.runners.JUnit4ClassRunner.createTest(JUnit4ClassRunner.java:72)
>     at
> org.junit.internal.runners.JUnit4ClassRunner.invokeTestMethod(JUnit4ClassRunner.java:79)
>     at
> org.junit.internal.runners.JUnit4ClassRunner.runMethods(JUnit4ClassRunner.java:51)
>     at
> org.junit.internal.runners.JUnit4ClassRunner$1.run(JUnit4ClassRunner.java:44)
>     at
> org.junit.internal.runners.ClassRoadie.runUnprotected(ClassRoadie.java:27)
>     at
> org.junit.internal.runners.ClassRoadie.runProtected(ClassRoadie.java:37)
>     at
> org.junit.internal.runners.JUnit4ClassRunner.run(JUnit4ClassRunner.java:42)
>     at
> org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62)
>     at
> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:140)
>     at
> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:127)
>     at org.apache.maven.surefire.Surefire.run(Surefire.java:177)
>     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>     at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>     at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>     at java.lang.reflect.Method.invoke(Method.java:585)
>     at
> org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:345)
>     at
> org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:1009)
>
>
> Results :
>
> Tests in error:
>
> testGeneration(org.apache.cxf.tools.wsdlto.javascript.WSDLToJavaScriptTest)
>
> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
>
>   

----------------------------
IONA Technologies PLC (registered in Ireland)
Registered Number: 171387
Registered Address: The IONA Building, Shelbourne Road, Dublin 4, Ireland