spring boot configuration annotation processor notconfigured解决方法

spring boot configuration annotation processor notconfigured解决方法

一、问题描述

我在使用ConfigurationProperties注解的时候idea出现提示信息spring boot configuration annotation processor notconfigured,但是却不影响程序的运行,如下图所示:

二、解决方法

"spring boot configuration annotation processor not configured"这个问题通常是由于构建工具没有正确配置Annotation Processor引起的。在使用Spring Boot时,如果项目中使用@Configuration注解,而构建工具没有正确配置Annotation Processor,就可能会遇到这个问题。

在项目的pom文件中引入spring-boot-configuration-processor依赖即可

yaml 复制代码
<dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-configuration-processor</artifactId>
            <optional>true</optional>
</dependency>
相关推荐
Wang's Blog19 小时前
Java 接入Redis: 服务启动停止与后台运行配置
java·服务器·redis
此时不提桶,更待何时20 小时前
01-04-B-垃圾回收面试与生产事故实战
java·jvm·面试
GreenTea20 小时前
GrokBot 核心成员 Lauren Tan:每月交付 2000 个 PR 的人,是怎么用 AI 的
前端·后端·架构
码事漫谈20 小时前
FDE:一个缩写,两种命运
后端
名字还没想好☜1 天前
Go context.AfterFunc 实战(Go 1.21):context 一取消就自动跑清理,告别手写 goroutine 监听 Done
后端·golang·go
鹿角片ljp1 天前
KV Cache 解析
java·算法
captain3761 天前
网络原理(9)-数据链路层
java·网络协议·java-ee
惊讶的猫1 天前
意图识别置信度和检索重排的分数
java
明月_清风1 天前
为什么最近开始关注 JEV?几个实战案例告诉你答案
人工智能·后端