LearnBoost/socket.io — pull request #1371 by 2fours (2013-12-13 14:28:10+00:00)
Title: Use static channels for node syncing.

Every time a connection is made, socket.io subscribes to 5 additional channels in redis to keep sync in state across multiple nodes (which are unsubscribed on disconnect). This causes problems with high numbers of concurrent connections, eg. 10000 concurrent = 50000 redis subscriptions, which causes redis to use orders of magnitude more CPU.

This patch uses 5 static channels to convey the sync information instead of subscribing and unsubscribing with every connection. The pub/sub count in redis now stays at 13 whether 10 users are connected, 10,000, or 100,000.