web services - Server push of data from Clojure to ClojureScript -
I am writing an application server in the closure which will use CloserSearch on Clauer.
- http-kit
- An efficient, idiomatic way for clients to push data from server to real-time events as core Want to find: .async
- Ring
(but I'm open to other possibilities)
Is there a good way to do this? Can provide examples / approaches?
I like to use, here it is, you just have to
wrap-ring-handler
For the 'Push' function, the most useful part is Alf's ASCIN handler. It builds on the top of Nati, there is not a thread model of connection, so the server side does not have to worry about counting the TCP connection.
Description of some party:
- Use a server-side aysnc handler, hold all client connections (channels)
- 60 (for example) seconds If there is no 'new data', send an empty response
- If there is any feedback on the server side, then send it.
- Customer side can send general HTTP requests to server
- When the customer receives a response, handle the body of the reaction, and then, again, send an http request again
- Please check the client and all proxy servers to set the correct timeout
Here are more ways:
Comments
Post a Comment