Event loop plus another event loop
jefftk at google.com
Thu Jan 22 13:55:39 UTC 2015
On Wed, Jan 21, 2015 at 5:00 PM, Yichun Zhang (agentzh)
<agentzh at gmail.com> wrote:
> You can register the fd of the socket created by your 3rd-party
> libraries into nginx's event model and use nginx's event loop to
> dispatch read/write events on it on the library's behalf.
Alternatively, and this is kind of a hack, you can run your other
event loop in a different thread and connect the two up with a pipe.
You give one end of the pipe to nginx to watch and you write to the
other end when you want to run your handler in the main nginx context.
More information about the nginx-devel