spring:
  cache:
    redis:
      time-to-live: 3600
    caffeine:
      spec: initialCapacity=5,maximumSize=500,expireAfterWrite=3600s
  redis:
    host: 127.0.0.1
    port: 6379
    password:
    database: 0
    lettuce:
      pool:
        max-active: 32
        max-wait: 300ms
        max-idle: 16
        min-idle: 8
  servlet:
    multipart:
      max-file-size: 100MB
      max-request-size: 100MB


#阿里sentinel熔断器
feign:
  httpclient:
    enabled: true
  sentinel:
    enabled: true
  compression:
    request:
      enabled: true
      mime-types: application/javascript,text/css,application/json,application/xml,text/html,text/xml,text/plain
      min-response-size: 10240
    response:
      enabled: true


#Log配置
logging:
  level:
    cn.ibizlab: debug
    {{packageName}}: debug
    org.springframework.boot.autoconfigure: ERROR

#zuul网关超时设置
ribbon:
  ReadTimeout: 60000
  ConnectTimeout: 60000

#系统是否开启权限验证、是否开启缓存
#缓存级别：无缓存(无配置项)、一级缓存(L1)、二级缓存(L2)
ibiz:
  systemid: {{system.codeName}}
  systemname: {{system.logicName}}
  enablePermissionValid: true
  cacheLevel: L1 #(L1)一级本地caffeine缓存;(L2)caffeine缓存+Redis缓存


### 启用Gzip压缩
server:
  port: {{#if app.httpPort}}{{app.httpPort}}{{else}}8080{{/if}}
  compression:
    enabled: true
    mime-types: application/javascript,text/css,application/json,application/xml,text/html,text/xml,text/plain
    min-response-size: 10240


#zuul网关路由设置
zuul:
  routes:
    {{#if system.enableWorkflow}}
    wfcore:
      path: /wfcore/**
      serviceId: ${ibiz.ref.service.wf:ibzwf-api}
      stripPrefix: true
    {{/if}}
    loginv7:
      path: /v7/login
      serviceId: ${ibiz.ref.service.uaa:ibzuaa-api}
      stripPrefix: false
    changepwd:
      path: /v7/changepwd
      serviceId: ${ibiz.ref.service.uaa:ibzuaa-api}
      stripPrefix: false
    uaa:
      path: /uaa/**
      serviceId: ${ibiz.ref.service.uaa:ibzuaa-api}
      stripPrefix: false
    config:
      path: /configs/**
      serviceId: ${ibiz.ref.service.uaa:ibzuaa-api}
      stripPrefix: false
    oucore:
      path: /ibzorganizations/**
      serviceId: ${ibiz.ref.service.ou:ibzou-api}
      stripPrefix: false
    oudict:
      path: /dictionarys/**/Ibzou**
      serviceId: ${ibiz.ref.service.ou:ibzou-api}
      stripPrefix: false
    ou:
      path: /ibzdepartments/**
      serviceId: ${ibiz.ref.service.ou:ibzou-api}
      stripPrefix: false
    uaadict:
      path: /dictionarys/**/SysOperator
      serviceId: ${ibiz.ref.service.uaa:ibzuaa-api}
      stripPrefix: false
    dict:
      path: /dictionarys/**
      serviceId: ${ibiz.ref.service.dict:ibzdict-api}
      stripPrefix: false
    disk:
      path: /net-disk/**
      serviceId: ${ibiz.ref.service.disk:ibzdisk-api}
      stripPrefix: false
    ou_sys_org:
      path: /sysorganizations/**
      serviceId: ${ibiz.ref.service.ou:ibzou-api}
      stripPrefix: false
    ou_sys_dept:
      path: /sysdepartments/**
      serviceId: ${ibiz.ref.service.ou:ibzou-api}
      stripPrefix: false
    lite-core:
      path: /lite/**
      serviceId: ${ibiz.ref.service.lite:ibzlite-api}
      stripPrefix: false
    sysauthlog:
      path: /sysauthlogs
      serviceId: ${ibiz.ref.service.uaa:ibzuaa-api}
      stripPrefix: false
  {{#each app.appEntities}}
    {{#serviceId}}
    {{lowerCase app.codeName}}-{{lowerCase codeName}}:
      path: /{{pluralize codeName}}/**
      serviceId: {{refServiceId}}
      stripPrefix: false
    {{/serviceId}}
  {{/each}}
  sensitive-headers:
    - Cookie,Set-Cookie,Authorization
