[zeromq-dev] PUB-SUB scalability
Steven Clark
steven.p.clark at gmail.com
Mon Aug 16 16:44:48 CEST 2010
I'm interested in how well PUB-SUB scales via TCP.
Let's say I have 1 PUB socket, publishing data on N topics. Each topic has
an average data rate of 1KB/sec. Let's further say there are 2*N SUB clients
scattered across the internet, each of which subscribes to 3 random topics.
So that's 6*N topic subscriptions. However, with SUB-side topic filtering,
each SUB client gets data from all topics. So that's 2*N*N KB/s of traffic
leaving the PUB socket (?).
Any guesses as to how high N could go before things go haywire? Is the
network bandwidth the limiting factor? If N is 30, that would be 30*30*2 =
1.8 MB/sec.
Does the situation improve if I provide a separate PUB socket for each
topic? It seems like that would reduce the total data rate leaving the PUB
socket to 6*N KB/sec.
So here, for the same bandwidth, N could be 300 (as opposed to 30 before)?
The downside being that I would have to create 300 PUB sockets, and bind to
300 different ports?
Please let me know if my reasoning is flawed.
Thanks!
-Steven
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20100816/e56e4970/attachment.htm>
More information about the zeromq-dev
mailing list