techhero-framework-gateway-local.yml 2.29 KB
Newer Older
Administrator committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
spring:
  redis:
    database: 10
    host: test-env
    port: 6379
    password: techhero
    timeout: 0
    pool:
      max-active: 8
      max-wait: -1
      max-idle: 8
      min-idle: 0
  rabbitmq:
    host: dev-env
    port: 5672
    username: techhero
    password: techhero
    virtual-host: /framework
    listener:
      simple:
        acknowledge-mode: manual  # 消息确认方式,其有三种配置方式,分别是none、manual(手动ack) 和auto(自动ack) 默认auto
    publisher-confirms: true #确认消息已发送到交换机(Exchange)
    publisher-returns: true #确认消息已发送到队列(Queue)
zuul:
  host:
26 27
    connect-timeout-millis: 20000
    socket-timeout-millis: 20000
Administrator committed
28 29 30 31 32 33 34 35 36 37 38 39 40
    max-total-connections: 500
  ignoredServices: '*'


hystrix:
  command:
    default:
      execution:
        timeout:
          enabled: true
        isolation:
          thread:
            #配置hystrix的超时时间,要大于(RibbonReadTimeout + RibbonConnectTimeout) * (MaxAutoRetries + 1) * (MaxAutoRetriesNextServer + 1)
41
            timeout-in-milliseconds: 20000
Administrator committed
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65
            strategy: SEMAPHORE
  thread-pool:
    default:
      coreSize: 10
      maxQueueSize: 1000
      queueSizeRejectionThreshold: 800
    circuitBreaker:
      requestVolumeThreshold: 100 #熔断失败个数 超过既发生短路 默认20个
    fallback:
      isolation:
        semaphore:
          maxConcurrentRequests: 50 #回退线程数量
security:
  sessions: stateless
  oauth2:
    client:
      client-id: gateway_client
      client-secret: techhero
    resource:
      jwt:
        key-uri: http://127.0.0.1:15803/oauth/token_key #解析jwt令牌所需要密钥的地址
        #key-value: techhero
    authorization:
      check-token-access: http://techhero-framework-oauth/oauth/check_token
66
      
Administrator committed
67 68 69 70 71 72 73 74 75 76
gateway:
  allowed:
    origins:
      - '*'
      - http://127.0.0.1:8084
      - http://127.0.0.1:15801
      - https://account.aliyun.com
      - https://datav.aliyun.com
      - http://datav.aliyun.com
      - http://cdn-service-datav.aliyun.com
77
      
Administrator committed
78 79 80 81 82 83 84 85 86 87 88 89 90 91 92
ignore:
  urls:
    - /*/open/**
    - /swagger/api-docs
    - /swagger-resources/**
    - /swagger-ui.html
    - /*/v2/api-docs
    - /webjars/**
    - /auth/**
    - /oss/**
    - /system/db/getUserListPage/**
    - /exam/dc/rest/dcKsjhb/getExamPlan
    - /system/vc/code