Thanks for the reply,

 

Using post_action could work, if we can sent to the @after_request_location 
enough reliable information. 

 

Can we use the all the variable documented in the ngx_http_core_module 
(http://nginx.org/en/docs/http/ngx_http_core_module.html#variables) ? Are there 
any other variables that we could use?

 

Although, I am a bit concerned by your comment “possibly not recommended to 
use”, could we clarify what you mean or what lead you to think it is not 
recommended?

 

Rergard,

 

Julien

 

 

From: Sergey Brester [mailto:serg.bres...@sebres.de] 
Sent: Tuesday, November 10, 2015 2:30 PM
To: nginx-devel@nginx.org
Cc: Julien FROMENT
Subject: Re: Tracking sent responses

 

Hi,

I'm sure you can do that using on-board "equipment" of nginx, without deep 
integrating to the nginx (without write of own module).

You can use for this a "post_action", something like:

   post_action @after_request_location;

But (There is always a "but":), according to my last known stand:

- the feature "post_action" is asynchronously;
- the feature is not documentated (and possibly not recommended to use);- if 
location "executed" in post_action uses upstreams (fcgi, proxy_pass, etc.), it 
will always breaks a keepalive connection to the upstream channel (possibly 
fixed, but I've missed).

Regards,
sebres.

Am 10.11.2015 19:51, schrieb Julien FROMENT:

        Hello,

         

        We would like to use Nginx to keep track of exactly what part of an 
upstream's server response was sent over a socket. Nginx could call an API 
asynchronously with the number of bytes sent over the socket for a given 
request.

         

        Here is the pseudo code:

          -- Client send a request

          -- Nginx processes the request and send it to the upstream

          ...

          -- The upstream returns the response

          -- Nginx sends the response to the client

          -- Nginx calls Async API with the number of bytes sent

         

        I read a little bit of "Emiller's Guide To Nginx Module Development", 
and I think we could write a Handler that provide some tracking information. 
But I am unsure if it is possible to hook it at a low enough level for our 
needs.

         

        Are there any expert on this mailing list that could provide us 
consulting services and guide us through the development of such functionality?

         

        Thanks in advance!

         

        Julien

        #
        " Ce courriel et les documents qui lui sont joints peuvent contenir des
        informations confidentielles ou ayant un caractè privéS'ils ne vous 
sont
        pas destiné nous vous signalons qu'il est strictement interdit de les
        divulguer, de les reproduire ou d'en utiliser de quelque maniè que ce
        soit le contenu. Si ce message vous a é transmis par erreur, merci d'en
        informer l'expéteur et de supprimer imméatement de votre systè
        informatique ce courriel ainsi que tous les documents qui y sont 
attaché"
         
         
                                       ******
         
        " This e-mail and any attached documents may contain confidential or
        proprietary information. If you are not the intended recipient, you are
        notified that any dissemination, copying of this e-mail and any 
attachments
        thereto or use of their contents by any means whatsoever is strictly
        prohibited. If you have received this e-mail in error, please advise the
        sender immediately and delete this e-mail and all attached documents
        from your computer system."
        #

         

        _______________________________________________
        nginx-devel mailing list
        nginx-devel@nginx.org
        http://mailman.nginx.org/mailman/listinfo/nginx-devel


#
" Ce courriel et les documents qui lui sont joints peuvent contenir des
informations confidentielles ou ayant un caractè privéS'ils ne vous sont
pas destiné nous vous signalons qu'il est strictement interdit de les
divulguer, de les reproduire ou d'en utiliser de quelque maniè que ce
soit le contenu. Si ce message vous a é transmis par erreur, merci d'en
informer l'expéteur et de supprimer imméatement de votre systè
informatique ce courriel ainsi que tous les documents qui y sont attaché"


                               ******

" This e-mail and any attached documents may contain confidential or
proprietary information. If you are not the intended recipient, you are
notified that any dissemination, copying of this e-mail and any attachments
thereto or use of their contents by any means whatsoever is strictly
prohibited. If you have received this e-mail in error, please advise the
sender immediately and delete this e-mail and all attached documents
from your computer system."
#

_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel

Reply via email to