Long Polling vs SSE vs WebSocket — Concept Check
Questions on Long Polling vs SSE vs WebSocket. Three patterns for pushing real-time data from server to client — long polling (HTTP hack), Server-Sent Events (one-way HTTP stream), and WebSocket (full-duplex TCP channel) — each with distinct trade-offs in complexity, scalability, and browser support.
Questions in this quiz
8 questions on Long Polling vs SSE vs WebSocket — Concept Check. Work through them here, then start the quiz to answer them and see your score.
1.A chat application needs real-time bidirectional communication between clients and the server. Which technology is most suitable?
- AHTTP/2
- BWebSocket
- CLong Polling
- DServer-Sent Events
2.A news website wants to push updates to users as soon as they are available, but the updates only flow from server to client. Which method should they use?
- AHTTP/1.1
- BLong Polling
- CServer-Sent Events
- DWebSocket
3.A developer claims that WebSockets are needed for any real-time application. What is a more efficient alternative for one-way server-to-client updates?
- AHTTP/2
- BAJAX
- CServer-Sent Events
- DLong Polling
4.A team notices high server load due to frequent client requests for updates. Which method could reduce the load by minimizing repeated requests?
- AServer-Sent Events
- BWebSocket
- CLong Polling
- DPolling
5.A stock trading platform requires low-latency updates in both directions between server and clients. Which protocol is best suited?
- ALong Polling
- BServer-Sent Events
- CWebSocket
- DHTTP/1.1
6.Which technology uses a persistent one-way HTTP stream for server-to-client communication?
- AWebSocket
- BServer-Sent Events
- CLong Polling
- DAJAX
7.A developer is using Long Polling but notices high latency in receiving updates. What could be a more efficient alternative?
- AHTTP/2
- BWebSocket
- CPolling
- DServer-Sent Events
8.A company wants to implement a real-time dashboard with minimal complexity. Which technology should they consider first?
- AServer-Sent Events
- BWebSocket
- CPolling
- DLong Polling