Async Nginx question

Simon Marechal simon at reblaze.com
Tue Nov 30 15:52:59 UTC 2021


Hello,

    I am trying to interface an asynchronous library with nginx, as a
module. I already asked Maxim Dounin (thanks!) about this, he gave me a few
pointers, and asked me to look at the memcache module about how it was done.

    I however wonder if that is a good example of what I am trying to
achieve, as in my use case it's more of a content filter module. That means
that when I return NGX_DONE from the NGX_HTTP_CONTENT_PHASE (is that the
right phase I picked? I need the headers and body), I will run this
asynchronous library. Once it has finished working, it should either return
a "block" response, and continue with normal processing (returning a static
file, proxy, etc.). While I have a notion of how I could return the "block"
answer, I am not sure how to resume the normal course of operations in the
other case.

    I hope I am making sense ... Is there a good module that runs at this
phase and is asynchronous?

Best regards,
Simon
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx-devel/attachments/20211130/33bf1fcc/attachment.htm>


More information about the nginx-devel mailing list