Predecessor to WebSockets
Explore the historical background of WebSockets.
Long polling, a real-time alternative
WebSocket is not the only real-time communication technology used in your applications. We may have restrictions in our application’s environment that prevent using a WebSocket, such as having very inconsistent client connectivity due to our application’s user profile. Since this course was published, there may even be a newly emerged technology that provides even better two-way web communication. It is crucial for our application maintenance that we do not design it solely around WebSocket usage.
Note: We have a WebSocket-powered application, not a WebSocket application.
A less efficient but still viable real-time communication layer is HTTP long polling. Phoenix ships with long polling support out-of-the-box, which means we can quickly add it to our server when necessary. We can even run WebSockets in ...