Skip to content

Optimize writing with Mono Publisher #22800

@smaldini

Description

@smaldini

AbstractServerResponse is currently masking the response body type information with the custom write barrier from ChannelSendOperator. In fact if the body is a Mono, we shouldn't require the barrier at all.

If we preserve the Mono information, the reactor netty response adapter can then preserve it too and call the underlying reactor-netty send(Publisher) with a Mono which should provide room for further optimization at that level.

Same thing on the client request side, where ReactorClientRequest#writeWith can be optimized to preserve the mono too.

Suggestions are implemented in :
https://github.com/spring-projects/spring-framework/tree/optimize-mono-bodies

Metadata

Metadata

Assignees

Labels

in: webIssues in web modules (web, webmvc, webflux, websocket)type: enhancementA general enhancement

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions