2

I am getting the following error only when running mvn clean:

An exception has occurred in the compiler (1.6.0_34). Please file a bug at the
Java Developer Connection (http://java.sun.com/webapps/bugreport) after
checking the Bug Parade for duplicates. Include your program and the following
diagnostic in your report.  Thank you.
java.lang.ArrayIndexOutOfBoundsException: 117920
at com.sun.tools.javac.zip.ZipFileIndex.get4ByteLittleEndian(ZipFileIndex.java:644)
at com.sun.tools.javac.zip.ZipFileIndex.access$500(ZipFileIndex.java:29)
at com.sun.tools.javac.zip.ZipFileIndex$ZipDirectory.readEntry(ZipFileIndex.java:740)
at com.sun.tools.javac.zip.ZipFileIndex$ZipDirectory.buildIndex(ZipFileIndex.java:720)
at com.sun.tools.javac.zip.ZipFileIndex$ZipDirectory.access$000(ZipFileIndex.java:652)
at com.sun.tools.javac.zip.ZipFileIndex.checkIndex(ZipFileIndex.java:261)
at com.sun.tools.javac.zip.ZipFileIndex.<init>(ZipFileIndex.java:209)
at com.sun.tools.javac.zip.ZipFileIndex.getZipFileIndex(ZipFileIndex.java:115)
at com.sun.tools.javac.util.DefaultFileManager.openArchive(DefaultFileManager.java:621)
at com.sun.tools.javac.util.DefaultFileManager.listDirectory(DefaultFileManager.java:309)
at com.sun.tools.javac.util.DefaultFileManager.list(DefaultFileManager.java:890)
at com.sun.tools.javac.jvm.ClassReader.fillIn(ClassReader.java:2130)
at com.sun.tools.javac.jvm.ClassReader.complete(ClassReader.java:1781)
at com.sun.tools.javac.code.Symbol.complete(Symbol.java:384)
at com.sun.tools.javac.comp.Enter.visitTopLevel(Enter.java:274)
at com.sun.tools.javac.tree.JCTree$JCCompilationUnit.accept(JCTree.java:446)
at com.sun.tools.javac.comp.Enter.classEnter(Enter.java:238)
at com.sun.tools.javac.comp.Enter.classEnter(Enter.java:252)
at com.sun.tools.javac.comp.Enter.complete(Enter.java:457)
at com.sun.tools.javac.comp.Enter.main(Enter.java:442)
at com.sun.tools.javac.main.JavaCompiler.enterTrees(JavaCompiler.java:822)
at com.sun.tools.javac.main.JavaCompiler.compile(JavaCompiler.java:727)
at com.sun.tools.javac.main.Main.compile(Main.java:353)
at com.sun.tools.javac.main.Main.compile(Main.java:279)
at com.sun.tools.javac.main.Main.compile(Main.java:270)
at com.sun.tools.javac.Main.compile(Main.java:87)
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:597)
at org.codehaus.plexus.compiler.javac.JavacCompiler.compileInProcess0(JavacCompiler.java:551)
at org.codehaus.plexus.compiler.javac.JavacCompiler.compileInProcess(JavacCompiler.java:526)
at org.codehaus.plexus.compiler.javac.JavacCompiler.compile(JavacCompiler.java:167)
at org.apache.maven.plugin.AbstractCompilerMojo.execute(AbstractCompilerMojo.java:678)
at org.apache.maven.plugin.CompilerMojo.execute(CompilerMojo.java:128)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
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:597)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
at      org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
    at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)

The environment which I am using is as follows:

  • Eclipse Galileo
  • Java 1.6.0_34 (32 bits on 64 machine)
  • JBoss Seam 2.2
  • JBoss AS 5.1

What could be the problem?

Pops
  • 30,199
  • 37
  • 136
  • 151
rodrigocprates
  • 498
  • 6
  • 22
  • Did you read the message? _"Please file a bug at the Java Developer Connection (http://java.sun.com/webapps/bugreport) after checking the Bug Parade for duplicates. Include your program and the following diagnostic in your report. Thank you."_ Look on the bugreport site to see if anybody else has reported this. – Jim Garrison Oct 01 '12 at 20:23
  • Seems like it has something to do with merged Jar files, but difficult to say without knowing more about what your project is doing. http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6232676 – noahlz Oct 01 '12 at 20:29
  • I don't know how to reproduce this error, so I didnt submit a report to bugreport's oracle page. I still working on how and why it exception is being thrown! – rodrigocprates Oct 01 '12 at 20:48
  • Without knowing more about your dependencies, plugins, etc. we can't really help you, other than point you in teh direction of similar-looking bugs. – noahlz Oct 01 '12 at 20:50
  • what do you need to know more about my environment? – rodrigocprates Oct 02 '12 at 13:35

3 Answers3

1

I didn't understand the problem but I found a solution: I cleaned my .m2 directory and reinstalled the jdk.

For sure it's that one kind of environment problems which we never can reproduce.

rodrigocprates
  • 498
  • 6
  • 22
0

I met this problem too. I solved this by reduce the pom dependency one by one.

At last I found that son-lib was the main reason for problem. So i deleted this dependency and all worked fine.

Koray Tugay
  • 22,894
  • 45
  • 188
  • 319
jayzc
  • 1
  • Can you explain _why_ deleting this line helps? Avoiding the problem is different from fixing it. –  Jul 27 '17 at 04:10
  • sorry i do not know why that worked. a little hard for me,if one day you work it out ,please let me know. thanks ahead – jayzc Jul 30 '17 at 13:29
0

Upgrading versions of Maven from 3.2 to 3.4 worked for me.

ojblass
  • 21,146
  • 22
  • 83
  • 132