2 ms·
It requires negligible (no?) traffic to keep a TCP socket 'continuously connected' when data is not being sent. (The only resource cost is the state at both end
by gojomo 19y ago
It requires negligible (no?) traffic to keep a TCP socket 'continuously connected' when data is not being sent. (The only resource cost is the state at both endpoints remembering the socket exists.) OTOH, every 'poll' involves a lot of socket and HTTP request/response overhead traffic -- even if there's no update necessary.
Still, this article overclaims the comet case. Polling is often easier to understand/implement/debug. It requires less server-side state and may be less likely to hit practical server-side implementation limits.