Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WebSocket to REST handlers Adapter #46

Closed
visur opened this issue Jul 3, 2019 · 0 comments
Closed

WebSocket to REST handlers Adapter #46

visur opened this issue Jul 3, 2019 · 0 comments

Comments

@visur
Copy link

visur commented Jul 3, 2019

Hi kataras and other contributors.
I use Iris framework to build REST api. I also added websockets to the project. And now I got an idea to use business logic of the REST api together with my socket controller. I want to build an adapter from websocket to http handlers for reuse code.
It will much improve response time, because it will pass authentication middleware only once per connection, it will not do tcp, ssl handshaking every single request.
Socket will get a message in Iris json/binary format. Event name will be name of http (REST) route. And body of this message will be exact body for the REST.
REST handler will do BL and will write result in "virtual" context, managed by adapter. After that adapter will pass this response message to the socket. Event name of the response will be the same route of request.
I need your help to do it, and of course it will be part of iris-contrib repository.
Thanks

@visur visur closed this as completed Sep 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant