anonymoussc
Apr 17, 2016 • 2 min read

Data Push using Server Sent Events

Server-sent events (SSE) is a technology where a browser receives automatic updates from a server via HTTP connection - Wikipedia.

Question and Answer

  1. How often are server-side events going to happen?
    • The higher this is the better data push (whether SSE or WebSockets) will be.
  2. How often are client-side events going to happen?
    • If such events occur less than once every five seconds, and especially if there is less than one event every second, WebSockets is going to be a better choice than SSE. If such events occur less than once every 5 to 10 seconds, this becomes a minor factor in the decision-making process.
  3. Are the server-side events not just fairly infrequent but also happening at predictable times?
    • When such events are less frequent than once a minute, data pull has the advantage that it won’t be holding open a socket. Be aware of the issues with lots of clients trying to all connect at the same time.

Reference :

  1. Server-sent events Web APIs MDN

  2. Data Push Apps With HTML5 SSE: Pragmatic Solutions for Real-World Clients, Darren Cook, O’Reilly Media, Mar 2014. isbn:9781430264484, isbn:9781449371937, amazon:1449371930, google:7gYiAwAAQBAJ

  3. Wikipedia


Ideas shape the course of history. - John Maynard Keynes

Post by: Anonymoussc (@anonymoussc)