Spring Boot Configuration Annotation Processor not configured 解决方案

Spring Boot Configuration Annotation Processor not configured 解决方案

问题背景:

进行Spring Boot配置文件部署时,发出警告Spring Boot Configuration Annotation Processor not configured,但是不影响运行。
Spring Boot Configuration Annotation Processor not configured 解决方案_第1张图片
问题解决方案:
在pom.xml文件中引入依赖

 <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-configuration-processor</artifactId>
            <optional>true</optional>
        </dependency>

如果引入的依赖报红,那就下载没有引入的资源,下载完成后点击下刷新即可。Spring Boot Configuration Annotation Processor not configured 就会消失。
如果我们的application.properties配置中有中文,可能会出现乱码
在setting -> editor -> file Encodings中修改编码
Spring Boot Configuration Annotation Processor not configured 解决方案_第2张图片
application.properties文件中添加

spring.http.encoding.charset=UTF-8

这样问题基本解决了

你可能感兴趣的:(Spring,Boot,spring,boot)