zoukankan      html  css  js  c++  java
  • 使用@ConfigurationProperties注解 提示 “Spring Boot Configuration Annotation Processor not found in classpath ”

    解决方案:

    在 pom.xml 添加依赖

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

    添加后,提示就没有了,假设你添加 spring-boot-configuration-processor 依赖 出现了这个提示

    因为依赖没放版本这个选项,所以它默认是最新的版本,把版本降低一下,依赖就可以下载了。

            <!-- 配置文件自动映射 -->
            <dependency>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-configuration-processor</artifactId>
                <version>2.1.6.RELEASE</version>
                <optional>true</optional>
            </dependency>

    最后记得 Build 一下项目。

  • 相关阅读:
    《构建之法》第四章的感悟
    单复利软件单元测试
    实验一 操作系统模仿cmd
    <构建之法>第一二三章感悟
    近期工作量统计
    复利计算3.0
    复利运算
    单利运算1
    复利计算6.0
    汉堡包
  • 原文地址:https://www.cnblogs.com/oukele/p/11390382.html
Copyright © 2011-2022 走看看