简体   繁体   中英

Eclipse JRE version Issue

i checked out 4 eclipse maven project in a new workspace, the issue is in eclipse proj it shows JRE5 or JRE6 but actually it refers JRE7

My eclipse default is JRE6. Things work fine in old workspace.

in pom.xml compiler plugin is correctly configured to 1.6 , still when i run "mvn install" i see it using JRE7 not 6. I want to use JRE6 for all projects have configured same in pom.xml and eclipse still always picks up JRE7

what am i doing wrong ??

在此处输入图片说明在此处输入图片说明

You need to configure the execution environments in Eclipse to use your preferred JDK. I suspect version 7 is currently configured for the J2SE-1.5 and JavaSE-1.6 environments.

  1. Don't use "Run as > Maven install" or any of the other direct Maven commands from Eclipse unless you have some major reason to do so. It'll just end up confusing both Eclipse and Maven. Run from the command-line if you need to run a specific Maven goal (like "package")
  2. After you set up the Maven compiler plugin, you need to update the project. In Eclipse, right-click the project folder and select "Maven > Update Project..."

earlier only JRE7 was installed hence the issue now added path for JDK6 working fine now

IS this setting WorkSpace specific ??

在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM