reactor / reactor-netty

TCP/HTTP/UDP/QUIC client/server with Reactor over Netty

Home Page:https://projectreactor.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Spring Cloud Gateway use reactor netty :Response header and response body packet capture were found to be separate

renjie6666 opened this issue · comments

Expected Behavior

Response header and response body packet capture found that they were merged into one TCP packet

Actual Behavior

Response header and response body packet capture were found to be separate

Steps to Reproduce

Only one routing configuration has been added to the configuration file, and the rest are using official code. The downstream servers use a http server built by Netty.
Then send http request to gateway.

Possible Solution

use byteMono.aggreate(), but it will introduce other issues such as generating a cancellation signal for the sequence and disconnecting the gateway and downstream services through doOnCancel()

Your Environment

  • Reactor version(s) used:0.9.15
  • Other relevant libraries versions (eg. netty, ...):4.1.55
  • JVM version (java -version):1.8
  • OS and version (eg. uname -a):ubuntu 20.0.4
  • Spring Cloud Gateway version: 2.2.5

@renjie6666 Reactor Netty 0.9.x is not supported. Whether there will be one packet or many depends on different prerequisites:

  • Whether there is Content-Length/Transfer-Encoding
  • What the body size is
  • What SO_RCVBUF/SO_SNDBUF configuration is
  • How Spring Cloud Gateway is implemented
  • etc.

I don't think there is Reactor Netty issue here.