News for hackers. Stuff that matters.
Re:WebSockets: caution required by bphogan on Thursday December 31, 2015 @10:38AM (#10817971)
I have a question - if you're only using sockets for push, why not use SSE instead? Or did you encounter serious issues with that?
Re:WebSockets: caution required by bradgessler on Thursday December 31, 2015 @03:42PM (#10819582)
SSE is fine except stupid Internet Explorer doesn't support it: http://caniuse.com/#feat=eventsource

A goal of Firehose is to have the fewest number of transports possible so the client doesn't have to spend much time negotiating the transport. I found WebSockets was more widely supported (http://caniuse.com/#feat=websockets) and HTTP long polling could take care of the rest.

Before I built Firehose I looked at socket.io, which had a ton of transports, but found that it was too slow, flakey, and unpredictable for our needs.

Re:WebSockets: caution required by jessaustin on Thursday December 31, 2015 @10:51AM (#10818047)
I've had good results with SSE in just the situation that GP describes: client actions come in as POSTs and the results of those are communicated to everyone via SSE. In most cases we don't even care about the 204 or whatever. If it's not on SSE then it didn't happen. b^)