Problem Description:
In eclipse, in the springboot project, when using @ConfigurationProperties(prefix = "person") annotation and yml file to do data binding, the spring-boot-configuration-processor dependency is added but there is still no prompt problem.
<!--导入配置文件处理器,配置文件进行绑定就会有提示-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-configuration-processor</artifactId>
<optional>true</optional>
</dependency>
Resolution process:
Add the following dependencies
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<java.version>1.8</java.version>
</properties>
Then update project
right click-"maven-" update project
Finally, maven install
right click- "run as -" maven install