ServerSentEventHttpMessageReader does not respect maxInMemorySize and is always limited to 256k messages #24312
Labels
in: web
Issues in web modules (web, webmvc, webflux, websocket)
type: regression
A bug that is also a regression
Milestone
Affects: 5.2.2, 5.2.1
To reproduce:
read
orreadMono
with 256k < len(message body) <= maxInMemorySizeExpected:
The problem is that while the data decoder passed to ServerSentEventHttpMessageReader is properly configured to support a larger maxInMemorySize, that decoder is only used to decode the
data
part of the message. Prior to that, the SSE's body is decoded through a different decoder (private static final StringDecoder stringDecoder = StringDecoder.textPlainOnly()
) which is not properly configured - nore is it accessible in any way - with the new limit.Note that to my understanding, prior to 5.2.0 there was no limit at all imposed to the body. Now there is one (see 89d053d by @rstoyanchev) , but we have no way to adjust it.
The text was updated successfully, but these errors were encountered: