springboot configuration annotation processor not found in classpath
今天使用springboot开发注解配置时,在添加完@ConfigurationProperties(prefix = “person”)注解之后,IDEA报这个错误,根据报错提示点击查看源文档:
https://docs.spring.io/spring-boot/docs/2.0.3.RELEASE/reference/html/configuration-metadata.html#configuration-metadata-annotation-processor
发现需要添加注解:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-configuration-processor</artifactId>
<optional>true</optional>
</dependency>
在项目中添加完注解运行发现已经没有问题了,但是IDEA还会提示:
处女座的我看着也很难受,重启IDEA刷新maven都不好使,只能先这么留着了,各位小伙伴有解决办法欢迎留言告知哦~