【发布时间】:2021-11-12 05:22:02
【问题描述】:
我正在使用 Spring webclient 连接到 netty webflux 服务器。
我在消费者空闲 20-30 分钟后收到此错误。
- Webflux 服务器正在 AWS EC2 中运行
- 由部署在 AWS EKS-EC2 中的 Spring 云网关前端
- AWS ELB 作为 Spring 云网关的入口负载均衡器
- 以前,由于 AWS ELB 空闲超时配置,我曾经在 webflux 服务器上超时。所以现在 webflux 服务每 20 秒向客户端发送一次心跳消息
是因为连接从服务器端关闭还是问题出在客户端?
reactor.netty.http.client.PrematureCloseException:
Connection prematurely closed DURING response
Suppressed:
reactor.core.publisher.FluxOnAssembly$OnAssemblyException:
Error has been observed at the following site(s):
|_ checkpoint ? Body from GET https://*** [DefaultClientResponse]
【问题讨论】:
-
我在 20-30 分钟后收到此错误
标签: spring-webflux spring-webclient