[zeromq-dev] On the performance of ZMQ_STREAM sockets

André Caron andre.l.caron at gmail.com
Wed Jan 22 04:30:40 CET 2014


FYI,

I just wrote a small HTTP server based on ZMQ_STREAM sockets and an
outdated version of http-parser[1] wrapped in some C++ objects with naïve
buffering.

I profiled it with "ab" and got some interesting results:
- ~6K req/sec without HTTP keep alive; and
- ~19.5K req/sec with HTTP keep alive.

This is a super naïve server, there's lots more to add in there that will
likely affect this performance, but it goes a long way towards
demonstrating the incredible job you guys have done with this library :-D

I have a few projects up on GitHub that implement some HTTP-related
protocols (WebSockets, FastCGI, SCGI, etc.) in a way that are independent
from the IO engine (FSMs for the win).  I've been experimenting with
several IO engines for C/C++ and hadn't yet found something that was simple
enough to let me focus on the interesting bits.  These tests prove that the
search is finally over :-)

I'll be wrapping that up in a ZeroMQ-based HTTP gateway in the upcoming
weeks.  I'll post a link to the GitHub project as soon as I post it up
(should be very soon).

[1]: https://github.com/joyent/http-parser

Cheers,

André
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20140121/657d9405/attachment.htm>


More information about the zeromq-dev mailing list