engine.io-server-java
engine.io-server-java copied to clipboard
Support for Spring Reactive
Is it possible to integrate this library with Spring reactive framework which is no longer supporting HttpServletRequests? Not able to use the Spring example here https://socketio.github.io/engine.io-server-java/spring-integration.html to integrate the library with Spring Webflux.
I'll need to explore this more. I'll get back to you.
Hi, Did you get a chance to look at this? We are already using Spring Webflux extensively and it will be great for us to integrate and use this library if it has support for Spring Webflux.
It seems like Spring Webflux indeed does not provide a way to get HttpServletRequest. Currently, the only way to use engine.io/socket.io with Spring Webflux is to add a servlet above Spring's DispatcherServlet.
Hopefully, I will figure out how to make engine.io work with Spring Webflux soon.
Great to know you are planning to figure this out. Will this be planned against any Java Engine.io release? Wondering whether this is some minor enhancement we can wait for few days or look for other options.
While I do hope to be able to get to this soon. If your need is urgent, I suggest trying out other solutions in the meantime.
It seems like it's possible to use Spring MVC and Spring Webflux together in a single project. If possible, please try that approach out.
I've had a look at this and it'll require significant rework of the library to make it compatible with Webflux. Needless to say, this will take some time. I'd advise trying out other methods in the meantime.