# 基础公用的配置参数放置在这份yml中
# 项目相关配置
agileboot:
  # 名称
  name: AgileBoot
  # 版本
  version: 1.8.0
  # 版权年份
  copyright-year: 2022
  # 实例演示开关
  demo-enabled: true
  # 获取ip地址开关
  addressEnabled: false
  # 验证码类型 math 数组计算 char 字符验证
  captchaType: math
  # 对应的公钥放在前端项目中的utils/rsaUtils类中
  rsaPrivateKey: MIICdQIBADANBgkqhkiG9w0BAQEFAASCAl8wggJbAgEAAoGBAKHoeQr6sIzfsUDMIdXK2FNzqnG+vnnUrTsJGF1f82MJ10cC5Aw53/ntHl+IjCBU0R8KwPVwjJLoDwhaPgO0ktHa3b0l6E+mqIVIniE20Nws3E0mJhFwJC/IxB7JAg8TkuNzflzvZjAO1ACwgkKGxq7Iutz4TocLeCfUkObXwc1fAgMBAAECgYAWwCzqDwnp8bDdkxGaEhPNvi4QJ6ZqRilFZ2TGEiqIGyTl9JEI6sT/QIOJFw3hqSltfDxbAMKwDe221b9rE9+hZhE2rrpwcTKuehob9Z8CObYeUHR9HG7Qb2tYRElvSCWo74iz2zajXAvJLjIE4MPuPYqXC5zOabH+EJ/eaOzVwQJBANmRkMlb+qzp1GWuqFMHP+5MeYhFwUHVX7fxKNA24oHldX8zjPIZ6d3vaRfliTvxOaz1T80acvJkkb7zHBmaW38CQQC+gfF8Lg+nvBY/S3wfOPL8FcntP16jdFhNNZmbOxq72ZmCfl5Zk5cYNBc4rDSrd9Sj4TkLLug+wrK6Wr117P4hAkBOVxnZR2NVy8SM8HzvmJauiZ7hMKzLtbcHlrBpeLnKqALM0JUZv7b0EPa4ghAOI2fvHU2kvrdRDGFmbkdZ+LilAkBnX8eT5MKl+A/yZJmDr7laRNB/poVKGNXZf55Md3P4Pwlnn/6+iLHSdmGrZPZnnOyLyKjVgqyPccLeEGMCXIlBAkAt2OMwss16OH2x79OcfBrabU5iCVbDHg56JYGbWP8KcPfvspxtL/4TdACRsa+yCMcI6L29Q4wn791SEEnE834a
  # 是否检查 i18n 资源文件（messages.properties）是否都有对应的键值对
  checkI18nKey: false
  traceRequestIdKey: AG-RequestId



## 开发环境配置
#server:
#  # 服务器的HTTP端口，默认为8080
#  port: 8080
#  servlet:
#    # 应用的访问路径
#    context-path: /
#  tomcat:
#    # tomcat的URI编码
#    uri-encoding: UTF-8
#    # 连接数满后的排队数，默认为100
#    accept-count: 1000
#    threads:
#      # tomcat最大线程数，默认为200
#      max: 800
#      # Tomcat启动初始化的线程数，默认值10
#      min-spare: 100

# 日志配置
logging:
  level:
    # 记得配置到包名
    com.agileboot: debug
    org.springframework: info
  pattern:
    console: "%date requestId:%X{${agileboot.traceRequestIdKey}} %thread %green(%level) [%cyan(%logger{10}):%magenta(%line)] %red(%method) | %msg%n"


# Spring配置
spring:
  # 资源信息
  messages:
    # 国际化资源文件路径
    basename: i18n/messages
    # 有些版本的 IDEA  会自动设置properties的编码为IOS-8859-1 请在IDEA配置里设置成UTF8
    encoding: UTF-8

  # 文件上传
  servlet:
     multipart:
       # 单个文件大小
       max-file-size:  10MB
       # 设置总上传的文件大小
       max-request-size:  20MB
  # 服务模块
  devtools:
    restart:
      # 热部署开关  线上记得关闭
      enabled: false
  # compatible with swagger
  mvc:
    pathmatch:
      matching-strategy: ANT_PATH_MATCHER
  jackson:
    deserialization:
      fail-on-unknown-properties: false
    serialization:
      write-dates-as-timestamps: false
    date-format: yyyy-MM-dd HH:mm:ss



# token配置
token:
    # 令牌自定义标识
    header: Authorization
    # 令牌密钥 TODO 记得更换
    secret: sdhfkjshBN6rr32df38
    # 自动刷新token的时间
    autoRefreshTime: 20

# MyBatis配置
mybatis-plus:
    # 搜索指定包别名 使用简短的类型名称来代替完整的类型名称
#    typeAliasesPackage: com.agileboot.orm.*
    # 配置mapper的扫描，找到所有的mapper.xml映射文件
    mapperLocations: classpath*:mapper/**/*Mapper.xml
    # 加载全局的配置文件
    configuration:
      cacheEnabled: true
      useGeneratedKeys: true
      defaultExecutorType: SIMPLE
      logImpl: org.apache.ibatis.logging.slf4j.Slf4jImpl
    global-config:
      refresh: true


# PageHelper分页插件
pagehelper:
  helperDialect: mysql
  supportMethodsArguments: true
  params: count=countSql

springdoc:
  api-docs:
    enabled: true
    path: /v3/api-docs
    groups:
      enabled: true
  # 配置需要生成接口文档的扫描包
  packages-to-scan: com.agileboot





