Nginx Logging to Zeromq Module - Sparkngin
steve at stevemorin.com
Tue Dec 10 01:14:05 UTC 2013
 I have been looking at that module and a couple others including
 My understanding is that nginx uses a number of worker process that are
isolated, but need to see how zeromq handles that and if a socket can me
shared. Given that they aren't thread safe I assume that is a no. I will
pay attention to this part
 Saw that, will look where a setup call can happen this is helpful.
 I have been reading Evan Miller's guide, thanks
* Planning on using zero-copy
* Not sure if redis would be faster under high load but that would be
pretty interesting to see.
On Tue, Dec 3, 2013 at 5:49 AM, W-Mark Kubacki <wmark+nginx at hurrikane.de>wrote:
> 2013/11/16 Steve Morin <steve at stevemorin.com>:
> > Does anyone have experience integrating zeromq with Nginx. I am looking
> > some pointers, to see what concerns I should look out for.
> > I am trying to contribute this code to a open source project.
> > -Steve
> This seems to me being a good template for what you want to accomplish:
>  http://www.binpress.com/app/nginx-redislog-module/998
> Keep in mind that »ØMQ sockets are not threadsafe« and don't share
> them between threads.
>  http://zguide.zeromq.org/page:all#Multithreading-with-MQ
> See also:
>  http://forum.nginx.org/read.php?2,243942,243986#msg-243986 (master
> process → init_module callback; don't define sockets here; zmq_init
> goes here)
>  http://www.evanmiller.org/nginx-modules-guide.html#definition
> A note on performance:
> • Use zero-copy wherever possible. (I would make a custom string an
> optional last part of a message.) — 
> • Does ØMQ have UDP or similar for PUB sockets? If so, use that.
> • I guess that logging or queuing through Redis will perform better
> than utilizing ØMQ for that matter iff everything is done on one
> machine under high load.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the nginx-devel