I'm running into a problem while trying to compile my project with Maven in Jenkins. I'm getting the following error: 'Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.0:compile (default-compile) on project spring-boot-demo: Fatal error compiling: error: invalid target release: 17'. I've tried looking up solutions, but I'm still stuck. Can anyone assist me with this?
2 Answers
It sounds like the issue is related to the Java version configuration. Make sure that Jenkins is using JDK 17, or the version your project expects. You can check the global tool configuration in Jenkins to verify this.
Another thing to consider is your pom.xml file. Double-check that the properties section specifies the correct Java version like this: `1717`.
Related Questions
Set Wordpress Featured Image Using Javascript
How To Fix PHP Random Being The Same
Why no WebP Support with Wordpress
Replace Wordpress Cron With Linux Cron
Customize Yoast Canonical URL Programmatically
[Centos] Delete All Files And Folders That Contain a String