Hi Maxim, thanks for you answer. I have the following scenario, I want to finalize the request for example with NGX_ERROR, let's say in REWRITE phase, how could I make the request pass through the filters, I was thinking that something like this would work, but it isn't.
ngx_chain_t out; ngx_http_send_header(r); rc = ngx_http_output_filter(r, &out); ngx_http_finalize_request(r, NGX_ERROR); Thanks, Antonio Il giorno ven 17 ago 2018 alle ore 01:28 Maxim Dounin <mdou...@mdounin.ru> ha scritto: > Hello! > > On Thu, Aug 16, 2018 at 12:36:05AM +0200, Antonio Nappa wrote: > > > I have two modules loaded and it looks like when I terminate a request > from > > one module by calling ngx_http_output_filter the body filter in the other > > module does not get called. The module with the body filter is loaded > first > > in the config (IMO it shouldn't matter). Do you have any suggestion on > how > > I can make the body filter called? > > Make sure you've wrote the config file of your module properly. > In particular, config file for a typical body filter should look > like: > > ngx_addon_name="ngx_http_foo_filter_module" > > ngx_module_type=HTTP_AUX_FILTER > ngx_module_name=ngx_http_foo_filter_module > ngx_module_incs= > ngx_module_deps= > ngx_module_srcs=$ngx_addon_dir/ngx_http_foo_filter_module.c > ngx_module_libs= > ngx_module_order= > > . auto/module > > Trying to configure a filter module with ngx_module_type=HTTP > won't work. > > -- > Maxim Dounin > http://mdounin.ru/ > _______________________________________________ > nginx-devel mailing list > nginx-devel@nginx.org > http://mailman.nginx.org/mailman/listinfo/nginx-devel >
_______________________________________________ nginx-devel mailing list nginx-devel@nginx.org http://mailman.nginx.org/mailman/listinfo/nginx-devel