maven startup error Fatal error compiling: invalid target release

created at 11-24-2021 views: 2


The error content is as follows

ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.3:compile (default-compile) on project nutzbook: Fatal error compiling: invalid goal release: 1.8 -> [Help 1]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1]

Fatal error compiling: invalid target release

problem and solution

jdk environment is different from jdk configured by `maven`
The jdk environment in the pom.xml file can be modified to the maven configuration

The way to modify pom.xml is as follows:



created at:11-24-2021
edited at: 11-24-2021: