On Spring MVC with annotations, ResponseBodyEmitter
return types (and its specialized variant SseEmitter
) are used to emit streaming values. Currently WebMvc.fn has support for asynchronous single value but not for SSE. I am wondering if ServerResponse.async(Object asyncResponse)
should be improved to support such use case.
Worth to notice, the emitter instance is designed to be passed to another component, see ResponseBodyEmitter
Javadoc for more details.
Comment From: poutsma
Currently WebMvc.fn has support for asynchronous single value but not for SSE.
Just so that other people reading this issue don't get confused: WebMvc.fn does support multiple values, in the form of a reactive streams Publisher.