idea 礼貌的报错了

当前的配置文件信息

# Aliyun OSS 配置
  Aliyun:
    OSS:
      endpoint: https://oss-cn-beijing.aliyuncs.com
      bucketName: javawebdev
      region: cn-beijing

以及

// AliyunOSSProperties.class

@Data
@Component
@ConfigurationProperties(prefix = "Aliyun.OSS")
public class AliyunOSSProperties {

    private String endpoint;
    private String bucketName;
    private String region;

}

修改了 Aliyun 之后,运行依旧报错,提示

***************************
APPLICATION FAILED TO START
***************************

Description:

Configuration property name 'aliyun.OSS' is not valid:

    Invalid characters: 'O', 'S', 'S'
    Bean: uploadFileController
    Reason: Canonical names should be kebab-case ('-' separated), lowercase alpha-numeric characters and must start with a letter

Action:

Modify 'aliyun.OSS' so that it conforms to the canonical names requirements.

需要修改 OSS 。

yml and yaml 文件的标签 不允许大写。小写与“-”分割,是正确的做法。

Canonical names should be kebab-case ('-' separated), lowercase alpha-numeric characters and must start with a letter

配置自定义内容的提示

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

Logo

魔乐社区(Modelers.cn) 是一个中立、公益的人工智能社区,提供人工智能工具、模型、数据的托管、展示与应用协同服务,为人工智能开发及爱好者搭建开放的学习交流平台。社区通过理事会方式运作,由全产业链共同建设、共同运营、共同享有,推动国产AI生态繁荣发展。

更多推荐