Spring cloud fegin 调度问题排查记录

1,071 阅读1分钟

问题描述

springcloud fegin 调度中 服务端报错 java.io.IOException: 你的主机中的软件中止了一个已建立的连接。

  • 解决方案

1、如果是文件下载流之类的情况 在这链接可以参考 SpringCloud 通过Feign 调用其他服务下载文件

2、客户端的配置文件中client超时未配置

feign:
  httpclient:
    connection-timeout: 60000
    enabled: true
  client:
    config:
      default:
        connectTimeout: 60000
        readTimeout: 60000