server:
  port: ${liquidnet.info.port}
  tomcat:
    uri-encoding: UTF-8
    maxThreads: 2000 #默认200
    minSpareThreads: 200 #默认10
    maxConnections: 20000 #默认10000
    acceptCount: 5000  #默认100
    processorCache: -1  #默认200
  servlet:
    context-path: ${liquidnet.info.context}
# -----------------------------------------------------------
knife4j:
  enable: true
  production: ${liquidnet.knife4j.disable}
  basic:
    enable: true
    username: ${liquidnet.security.username}
    password: ${liquidnet.security.password}
# -----------------------------------------------------------
logging:
#  config: ${liquidnet.logfile.config}
  file:
    name: ${liquidnet.logfile.path}/${liquidnet.logfile.name}.log
    max-size: 200MB
    max-history: ${liquidnet.logfile.max-history}
  pattern:
    file: '%d{yyyy-MM-dd HH:mm:ss.SSS} [%level] %X{lnsTranceId} [%logger{56}:%line] - %msg%n'
    console: '%d{yyyy-MM-dd HH:mm:ss.SSS} [%level] %X{lnsTranceId} [%logger{56}:%line] - %msg%n'
    rolling-file-name: ${liquidnet.logfile.path}/${liquidnet.logfile.name}-%d{yyyy-MM-dd}.%i.log
  level:
    root: error
    #以下是为指定包设置日志级别
    com.liquidnet.service.feign: error
    com.liquidnet: ${liquidnet.logfile.level}
# -----------------------------------------------------------
eureka:
#  client:
#    register-with-eureka: true
#    fetch-registry: true
#    serviceUrl:
#      defaultZone: http://${liquidnet.security.username}:${liquidnet.security.password}@${liquidnet.eureka.host}/eureka-server/eureka
  instance:
    hostname: ${spring.cloud.client.ip-address}
    lease-expiration-duration-in-seconds: 15 #服务过期时间配置,超过这个时间没有接收到心跳EurekaServer就会将这个实例剔除
    lease-renewal-interval-in-seconds: 5 #服务刷新时间配置，每隔这个时间会主动心跳一次
    prefer-ip-address: true
    instance-id: ${spring.application.name}:${spring.cloud.client.ip-address}:${spring.application.instance_id:${server.port}}
# -----------------------------------------------------------
#actuator/info
info:
  app:
    name: ${liquidnet.info.name}
  company:
    name: zhengzai.tv
  build:
    groupId: '@project.groupId@'
    artifactId: '@project.artifactId@'
    version: '@project.version@'
# -----------------------------------------------------------
mybatis-plus:
  mapper-locations: classpath*:com.liquidnet.service.*.mapper/*Mapper.xml
# -----------------------------------------------------------
spring:
  application:
    name: ${liquidnet.info.name}
  servlet:
    multipart:
      max-file-size: 350MB
      max-request-size: 350MB
  profiles:
    include: common-service #这里加载management相关公共配置
#  rabbitmq:
#    addresses: ${liquidnet.rabbitmq.host}
#    port: ${liquidnet.rabbitmq.port}
#    username: ${liquidnet.rabbitmq.username}
#    password: ${liquidnet.rabbitmq.password}
#    virtual-host: ${liquidnet.rabbitmq.virtual-host}
#    connection-timeout: ${liquidnet.rabbitmq.connection-timeout}
  redis:
    queue:
      database: ${liquidnet.redis.queue.database}
      port: ${liquidnet.redis.queue.port}
      host: ${liquidnet.redis.queue.host}
      password: ${liquidnet.redis.queue.password}
      lettuce:
        pool:
          max-active: 8
          max-wait: -1
          max-idle: 8
          min-idle: 0
    kylin:
      database: 15
      dbs: ${liquidnet.redis.kylin.dbs}
      port: ${liquidnet.redis.kylin.port}
      host: ${liquidnet.redis.kylin.host}
      password: ${liquidnet.redis.kylin.password}
      lettuce:
        pool:
          max-active: 8
          max-wait: -1
          max-idle: 2
          min-idle: 0
    dragon:
      database: 15
      dbs: ${liquidnet.redis.dragon.dbs}
      port: ${liquidnet.redis.dragon.port}
      host: ${liquidnet.redis.dragon.host}
      password: ${liquidnet.redis.dragon.password}
      lettuce:
        pool:
          max-active: 8
          max-wait: -1
          max-idle: 2
          min-idle: 0
    sweet:
      database: 15
      dbs: ${liquidnet.redis.sweet.dbs}
      port: ${liquidnet.redis.sweet.port}
      host: ${liquidnet.redis.sweet.host}
      password: ${liquidnet.redis.sweet.password}
      lettuce:
        pool:
          max-active: 8
          max-wait: -1
          max-idle: 2
          min-idle: 0
    adam:
      database: 15
      dbs: ${liquidnet.redis.adam.dbs}
      port: ${liquidnet.redis.adam.port}
      host: ${liquidnet.redis.adam.host}
      password: ${liquidnet.redis.adam.password}
      lettuce:
        pool:
          max-active: 8
          max-wait: -1
          max-idle: 2
          min-idle: 0
    candy:
      database: 15
      dbs: ${liquidnet.redis.candy.dbs}
      port: ${liquidnet.redis.candy.port}
      host: ${liquidnet.redis.candy.host}
      password: ${liquidnet.redis.candy.password}
      lettuce:
        pool:
          max-active: 8
          max-wait: -1
          max-idle: 2
          min-idle: 0
    stone:
      database: 15
      dbs: ${liquidnet.redis.stone.dbs}
      port: ${liquidnet.redis.stone.port}
      host: ${liquidnet.redis.stone.host}
      password: ${liquidnet.redis.stone.password}
      lettuce:
        pool:
          max-active: 8
          max-wait: -1
          max-idle: 2
          min-idle: 0
    goblin:
      database: 15
      dbs: ${liquidnet.redis.goblin.dbs}
      port: ${liquidnet.redis.goblin.port}
      host: ${liquidnet.redis.goblin.host}
      password: ${liquidnet.redis.goblin.password}
      lettuce:
        pool:
          max-active: 8
          max-wait: -1
          max-idle: 2
          min-idle: 0
  data:
    mongodb:
      uri: mongodb://${liquidnet.mongodb.user}:${liquidnet.mongodb.pwd}@${liquidnet.mongodb.host}/?authSource=admin&maxPoolSize=200&waitQueueMultiple=100
      sslEnabled: ${liquidnet.mongodb.sslEnabled}
      database: ${liquidnet.mongodb.database}
  datasource:
    name: ${liquidnet.mysql.database-name}
    url: jdbc:mysql://${liquidnet.mysql.urlHostAndPort}/${liquidnet.mysql.database-name}?serverTimezone=Asia/Shanghai&characterEncoding=utf-8&useSSL=false
    username: ${liquidnet.mysql.username}
    password: ${liquidnet.mysql.password}
#    type: org.apache.tomcat.jdbc.pool.DataSource
    driver-class-name: com.mysql.cj.jdbc.Driver
    hikari:
      maximum-pool-size: 45
      connection-timeout: 60000
      minimum-idle: 8
      connection-test-query: SELECT 1
# -----------------------------------------------------------

# -----------------------------------------------------------
global-auth:
  exclude-url-pattern: # 模式I（与模式II互斥）
#    - ${liquidnet.info.context}/**
    # 健康检查
    - ${liquidnet.info.context}/health
  include-url-pattern: # 模式II（与模式I互斥）
#    - ${liquidnet.info.context}/**
# -----------------------------------------------------------

# -----------------------------------------------------------