报错:
1 系统资源不足。 2 有关详细信息, 请参阅以下堆栈跟踪。 3 java.lang.OutOfMemoryError: Java heap space 4 at com.sun.tools.javac.file.ZipFileIndex.readBytes(ZipFileIndex.java:389) 5 at com.sun.tools.javac.file.ZipFileIndex.read(ZipFileIndex.java:359) 6 at com.sun.tools.javac.file.ZipFileIndexArchive$ZipFileIndexFileObject.openInputStream(ZipFileIndexArchive.java:151) 7 at com.sun.tools.javac.jvm.ClassReader.fillIn(ClassReader.java:2510) 8 at com.sun.tools.javac.jvm.ClassReader.complete(ClassReader.java:2442) 9 at com.sun.tools.javac.jvm.ClassReader.access$000(ClassReader.java:76) 10 at com.sun.tools.javac.jvm.ClassReader$1.complete(ClassReader.java:240) 11 at com.sun.tools.javac.code.Symbol.complete(Symbol.java:574) 12 at com.sun.tools.javac.code.Symbol$ClassSymbol.complete(Symbol.java:1037) 13 at com.sun.tools.javac.code.Symbol$ClassSymbol.members(Symbol.java:978) 14 at com.sun.tools.javac.jvm.ClassReader$AnnotationDeproxy.visitEnumAttributeProxy(ClassReader.java:1854) 15 at com.sun.tools.javac.jvm.ClassReader$EnumAttributeProxy.accept(ClassReader.java:1676) 16 at com.sun.tools.javac.jvm.ClassReader$AnnotationDeproxy.deproxy(ClassReader.java:1814) 17 at com.sun.tools.javac.jvm.ClassReader$AnnotationDefaultCompleter.run(ClassReader.java:1918) 18 at com.sun.tools.javac.comp.Annotate.flush(Annotate.java:143) 19 at com.sun.tools.javac.comp.Annotate.enterDone(Annotate.java:129) 20 at com.sun.tools.javac.comp.Enter.complete(Enter.java:512) 21 at com.sun.tools.javac.comp.Enter.main(Enter.java:471) 22 at com.sun.tools.javac.main.JavaCompiler.enterTrees(JavaCompiler.java:982) 23 at com.sun.tools.javac.processing.JavacProcessingEnvironment$Round.enterTrees(JavacProcessingEnvironment.java:1015) 24 at com.sun.tools.javac.processing.JavacProcessingEnvironment$Round.<init>(JavacProcessingEnvironment.java:902) 25 at com.sun.tools.javac.processing.JavacProcessingEnvironment$Round.next(JavacProcessingEnvironment.java:921) 26 at com.sun.tools.javac.processing.JavacProcessingEnvironment.doProcessing(JavacProcessingEnvironment.java:1187) 27 at com.sun.tools.javac.main.JavaCompiler.processAnnotations(JavaCompiler.java:1170) 28 at com.sun.tools.javac.main.JavaCompiler.compile(JavaCompiler.java:856) 29 at com.sun.tools.javac.main.Main.compile(Main.java:523) 30 at com.sun.tools.javac.api.JavacTaskImpl.doCall(JavacTaskImpl.java:129) 31 at com.sun.tools.javac.api.JavacTaskImpl.call(JavacTaskImpl.java:138) 32 at org.codehaus.plexus.compiler.javac.JavaxToolsCompiler.compileInProcess(JavaxToolsCompiler.java:126) 33 at org.codehaus.plexus.compiler.javac.JavacCompiler.performCompile(JavacCompiler.java:174) 34 at org.apache.maven.plugin.compiler.AbstractCompilerMojo.execute(AbstractCompilerMojo.java:1075) 35 at org.apache.maven.plugin.compiler.CompilerMojo.execute(CompilerMojo.java:168)
查了资料,改了好多配置,最后增加如下配置,问题解决
setting -> maven -> Runner -> VM Options 值为:-Xms512m -Xmx512m (可根据实际配置来)