Re:Server-Sent Events: The simplest realtime browser spec
by skue on Friday April 04, 2014 @07:15PM
(#7535077)
Yes, the umbrella term for this HTTP server push is Comet[1], and it's been around in various forms for years. But standardizing this in the form of server-sent events is a very Good Thing, especially with support baked into modern browsers.
Also, unlike WebSockets it's also easy to add SSE support for mobile clients. I've implemented a SSE client class in just over 100 lines of Java, and it's similarly easy to do this with NSURLConnection/NSURLSession on iOS. The W3 standard provides an implementation section that reads like pseudocode.[2]
Also, unlike WebSockets it's also easy to add SSE support for mobile clients. I've implemented a SSE client class in just over 100 lines of Java, and it's similarly easy to do this with NSURLConnection/NSURLSession on iOS. The W3 standard provides an implementation section that reads like pseudocode.[2]
[1]: https://en.wikipedia.org/wiki/Comet_%28programming%29
[2]: http://dev.w3.org/html5/eventsource/#event-stream-interpreta...