#eureka client配置
eureka:
  client.serviceUrl.defaultZone: http://admin:prolog00212@192.168.1.21:6001/eureka/
#  instance.ipAddress: 192.168.0.168  # 指定此实例的ip

spring:
  application:
    name: upcloud-base-wh-inbound-xiantao
  devtools:
    restart:
      enabled: true
  #redis配置
  redis:
    cluster:
      nodes: 192.168.1.17:6379,192.168.1.17:6380,192.168.1.18:6379,192.168.1.18:6380,192.168.1.19:6379,192.168.1.19:6380
    password: prolog-redis-0212
  #链路跟踪
  zipkin:
    base-url: http://192.168.0.167:10002
    sender.type: rabbit
    rabbitmq.queue: trace #默认配置
  sleuth:
    enable: false
    sampler:
      probability: 1.0
  rabbitmq:
    addresses: 192.168.1.17:5672,192.168.1.18:5672,192.168.1.19:5672
    username: common
    password: prolog-mq-20191229
    virtual-host: /upcloud-xiantao
    template:
      mandatory: true
    publisher-confirms: true
    listener:
      simple:
        acknowledge-mode: manual # 手动应答
        auto-startup: true
        default-requeue-rejected: false # 不重回队列
        concurrency: 5  # 允许并发数
        max-concurrency: 20
#        prefetch: 1 # 每次只处理一个信息
        retry:
          enabled: true
        prefetch: 300
  datasource:
  #    TODO 数据库url
    driverClassName: com.mysql.jdbc.Driver
    url: jdbc:mysql://192.168.1.11:3308/upcloud_biz_inbound?useSSL=false&serverTimezone=CTT&useUnicode=true&characterEncoding=utf-8&allowMultiQueries=true
    username: root
    password: prolog0212
    #使用druid数据源
    initialSize: 1 #初始化大小
    minIdle: 5 #最小空閒
    maxActive: 10 #最大連接數
    maxWait: 60000 #最大等待時間
    minEvictableIdleTimeMillis: 25200000 #最小生存時間
prolog:
  auth:
    redis:
#      timeout: 18000
      namespace: "upcloud-base-xiantao:"
  dao:
    performance: #sql性能监控配置
      enable: true #开启性能监控，默认关闭，建议开发环境开启
      showSql: true #开启打印sql，默认false
      logSlowQuery: true #记录慢sql，默认false
      slowQueryInterval: 3000 #慢sql判断值，单位ms，默认3000ms
    dialect: mysql
    mybatis:
      mapperLocations: classpath:mappers/mysql/*.xml
  security:
    accessTokenValiditySeconds: 3600
    refreshTokenValiditySeconds: 30000
  wms:
    print:
      printUrl3: http://116.54.19.104:26819/files/YS_TZ.grf
      printUrl: http://116.54.19.104:26819/files/SJ_BQ.grf
      printUrl2: http://116.54.19.104:26819/files/ZJ_MX.grf
      printUrl4: http://116.54.19.104:26819/files/ZJ_HZ.grf
      printSolution: batch_order.grf
      printSolution1: SJ_BQ.grf
      preview1: false
      printName: null
      printCount: 1
      preview: true
    instock:
      enablePadStoreTemperature: false
    rqc:
      enableExpire: false
      
    enablePush: false #是否推送任务
         
  rabbitmqManage:
    username: admin
    password: prolog-mq-20191229
    host: 192.168.1.18
  tx:
    url: "http://192.168.1.21:7000/tx/manager/"
  serarch:
    url: "http://service-data-api-base-xiantao/search"
  service:
    item: upcloud-base-item-xiantao
    warehouse: upcloud-base-wh-xiantao
    chain: upcloud-base-chain-xiantao
    inventory: upcloud-base-inventory-xiantao
    control: upcloud-base-wh-control-xiantao
    strategy: upcloud-base-strategy-xiantao
    dataExchange: data-exchange  
logging:
  config: classpath:log4j2-cube.xml
  level:
    com.netflix.discovery.shared.resolver.aws.ConfigClusterResolver: WARN

management:
  endpoints:
    web:
      exposure:
        include: "*"
        exclude: "shutdown"
  endpoint:
    logfile.external-file: /usr/local/logs/upcloud-base-wh-inbound-cube192.168.1.206.9817/info.log  #info日志文件路径 等效logging.file或者logging.path
    health.show-details: always #开启多个健康指标

# 超时配置
ribbon:
  ReadTimeout: 120000
  ConnectTimeout: 10000
  MaxAutoRetries: 1
  MaxAutoRetriesNextServer: 1
  
feign.hystrix.enabled: true #启用熔断
hystrix:
  threadpool:
   default:
      coreSize: 20 #线程隔离，默认线程池大小为10
      maxQueueSize: 500
      queueSizeRejectionThreshold: 400
  command:
    default: #默认全局配置
      execution:
        timeout:
          enabled: true
        isolation:
          thread:
            timeoutInMilliseconds: 525000
