zoukankan      html  css  js  c++  java
  • gateway网关配置转发和熔断配置

    ##服务器端口配置
    server:
      port: 10001
    spring:
      application:
        name: operate-gateway-dev
      cloud:
        nacos:
          discovery:
            server-addr: 10.210.12.87:8849   #配置Nacos地址
        gateway:
          routes:
            - id: url-proxy-0 #文件导出接口,单独设置超时时间
              uri: lb://ymall-overseas-dev #lb://服务名
              predicates:
                - Path=/lhwTest/lhw/order/export
              filters:
                - name: Hystrix
                  args:
                    name: fallbackExp
                    fallbackUri: forward:/fallBack
    
            - id: url-proxy-1 #转发到lhwTest接口
    uri: lb:
    //lhwTest-dev #lb://服务名
    predicates: - Path=/lhwTest/**
    filters: - name: Hystrix args: name: fallbackcmd fallbackUri: forward:/fallBack - id: url-proxy-2 #转发到lhwTest2接口
    uri: lb://lhwTest2-dev #lb://服务名
    predicates: - Path=/lhwTest2/**
    filters: - name: Hystrix args: name: fallbackcmd fallbackUri: forward:/fallBack # Hystrix 配置 hystrix: command: default: execution: isolation: thread: timeoutInMilliseconds: 6000 #默认超时时间 fallbackcmd: execution: isolation: thread: timeoutInMilliseconds: 2000 # Hystrix 的 fallback 时间 fallbackExp: execution: isolation: thread: timeoutInMilliseconds: 60000 # Hystrix 的 fallback 时间 threadpool: default: coreSize: 100 # Hystrix 更改默认并发数配置 logging: config: classpath:log4j2-dev.xml
  • 相关阅读:
    fixed解决方案
    阿里巴巴全部行业分类
    下边的flash挡住了上面的元素
    Response.Status
    分割DataTable
    window.print() 指定打印的区域
    oracle .1
    最新:电视台mms地址在线观看
    Access 时间比较错误
    Entity Framework linq
  • 原文地址:https://www.cnblogs.com/linhongwenBlog/p/14959365.html
Copyright © 2011-2022 走看看