Our implementation of Server Sent Events (SSE), currently SseEmitter (MVC) and ServerSentEvent (WebFlux), do not guard against invalid characters if the application mistakenly inserts such characters in the id or event event types. Both implementations also behave differently when it comes to escaping comment multi-line events.
This issue should address the following:
- align behavior for comment events
- reject invalid characters for the
id and eventcases
- optimize
String concatenation and memory usage where possible