Hacker News new | ask | show | jobs
by apitman 546 days ago
The site mentions battery-efficiency specifically. I'm curious what features does Mercure provide in that direction?
2 comments

SSE/Mercure (as WebSockets) is much battery-efficient than polling (push vs poll, less bandwidth used).

Additionally, on controlled environnements, SSE can use a « push proxy » to wake up the device only when necessary: https://html.spec.whatwg.org/multipage/server-sent-events.ht...

It comes down to all the extra bytes sent and processed (local and remote, and in flight) by long polling. SSE events are small while other methods might require multiple packets and all the needless headers throughout the stack, for example.