Hacker News new | past | comments | ask | show | jobs | submit login

imo, Server-Sent Events are the better solution for realtime updates. Sometimes you need the stateful bidirectional protocol WebSockets offer, but most of the time HTTP for RPC and SSE for streaming updates gets you where you need to go with standard HTTP, no special protocols.



There's one scenario where websockets win: When you don't want your client-to-server calls to get reordered in-flight.

Unfortunately the browser javascript "fetch API" still doesn't implement streaming request bodies. If it did, websockets would be obsolete.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: