[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.7.0:compile (default-compile) on project xxx: Fatal error compiling: 无效的目标发行版: 11 -> [Help 1]
或者是Fatal error compiling: 无效的标记: --release
这个Fatal error compiling: 无效的目标发行版: 11坑的突破天际!
别的问题:mybatis警告
如果你的项目使用了mybatis,那可能会在启动时看到如下日志
12345
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.apache.ibatis.reflection.Reflector (file:/.../org/mybatis/mybatis/3.4.6/mybatis-3.4.6.jar) to method java.lang.Integer.getChars(int,int,byte[])
WARNING: Please consider reporting this to the maintainers of org.apache.ibatis.reflection.Reflector
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
别的问题:Unable to import maven project: See logs for details
当你对pom.xml 做修改保存,IDEA右下角会有提示 Unable to import maven project: See logs for details,提示让我们去看日志.
点击[Help]–>[Show Log in Finder],可以看到错误信息如下:
12345678910111213141516171819202122
2018-11-10 14:55:54,580 [58702502] WARN - ution.rmi.RemoteProcessSupport - Unrecognized option: -d64
2018-11-10 14:55:54,580 [58702502] WARN - ution.rmi.RemoteProcessSupport - Error: Could not create the Java Virtual Machine.
2018-11-10 14:55:54,580 [58702502] WARN - ution.rmi.RemoteProcessSupport - Error: A fatal exception has occurred. Program will exit.
2018-11-10 14:55:54,656 [58702578] WARN - ution.rmi.RemoteProcessSupport - Unrecognized option: -d64
2018-11-10 14:55:54,656 [58702578] WARN - ution.rmi.RemoteProcessSupport - Error: Could not create the Java Virtual Machine.
2018-11-10 14:55:54,656 [58702578] WARN - ution.rmi.RemoteProcessSupport - Error: A fatal exception has occurred. Program will exit.
2018-11-10 14:55:54,657 [58702579] ERROR - #org.jetbrains.idea.maven - Cannot reconnect.
java.lang.RuntimeException: Cannot reconnect.
at ...
Caused by: java.rmi.RemoteException: Cannot start maven service; nested exception is:
com.intellij.execution.ExecutionException: Unrecognized option: -d64
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
at ...
Caused by: com.intellij.execution.ExecutionException: Unrecognized option: -d64
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
at com.intellij.execution.rmi.RemoteProcessSupport.acquire(RemoteProcessSupport.java:159)
at org.jetbrains.idea.maven.server.MavenServerManager.create(MavenServerManager.java:158)
... 37 more