[zeromq-dev] Why router address is string, not integer?
Martin Sustrik
sustrik at 250bpm.com
Wed Dec 7 13:37:11 CET 2011
Hi,
> I'm making a server program, which need to handle up to 10000 untrust client.
> Usually, each client will send about 20 - 30 message per second.
> When a message is coming, the server get the message's address, which is a string.
> And the server want to know where the message come from.
> So, the server need do a string-hash operation.
>
> I have not yet analyzed whether it have performance issues.
> But I think, if the address is a integer, then the program will run faster.
> So I'm wondering why the router address is a string, not integer?
Internally, in 3.1 version, the auto-generated identity contains 4 byte
integer. However, it's possible to set the identity by hand
(ZMQ_IDENTITY) and in that case string is more palatable.
Martin
More information about the zeromq-dev
mailing list