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


hystrix:
  command:
    default:
      execution:
        timeout:
          enabled: true
        isolation:
          thread:
            #配置hystrix的超时时间,要大于(RibbonReadTimeout + RibbonConnectTimeout) * (MaxAutoRetries + 1) * (MaxAutoRetriesNextServer + 1)
            timeout-in-milliseconds: 20000
            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:
65
      check-token-access: http://techhero-framework-auth/oauth/check_token
Administrator committed
66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92
      
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
      
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