解决Maven项目 Missing artifact jdk.tools:jdk.tools:1.7的错误
因学习项目需要,在pom.xml添加hbase-client依赖的时候提示解决Maven工程中报 Missing artifact jdk.tools:jdk.tools:1.7的提示信息,之前遇到这样的情况都是到\repository仓库删除.lastupdated文件再保存,这次不管用了。看到是jdk的提示,是不是我jdk的问题,后来查看是项目中的仓库找不到这个jdk。

记得之前是建立lib文件夹与src平级,放个tools.jar进去就可以。在pom.xml添加依赖就可以了
<dependency>
      <groupId>jdk.tools</groupId>
      <artifactId>jdk.tools</artifactId>
      <version>1.7</version>
      <scope>system</scope>
      <systemPath>${JAVA_HOME}/lib/tools.jar</systemPath>
	</dependency>
另外一个方法不知按照提示的目录层次拷贝toos.jar到仓库中是否可行,回家再试~
 
                    
                
 
 
                
            
         浙公网安备 33010602011771号
浙公网安备 33010602011771号