在使用eclipse 中用maven去构建spring boot项目时,pom.xml如下:
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>zl.isep</groupId>
<artifactId>ZL_ISEP</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>1.5.9.RELEASE</version>
</parent>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
</dependencies>
</project>
项目一直出现红叉,但并不影响运行,感觉很是别扭!
原因:Description Resource Path Location Type Project configuration is not up-to-date with pom.xml. Select
解决办法:选择项目--》右击选择Maven--》点击Update Maven Project 进入后选择报错的项目--》点击OK即可