See
http://wiki.nginx.org/Phases
access_by_lua sits in the access phase; your lua code will run, and if
the transaction doesn't quit, it will get passed down to the next phases
(eventually the content phase, where proxy_pass sits). The lua code
doesn't call proxy_pass, that gets handled by the nginx worker itself.
If you don't want to proxy_pass if you meet a given condition, you can
ngx.say() your capture, then ngx.exit(200) to stop transaction
processing (instead of the return you have now)
On 06/26/2014 03:58 AM, Peter G wrote:
> If i use access_by_lua will it not call proxy_pass ?
>
> On Wednesday, June 25, 2014 10:39:36 PM UTC+5:30, rpaprocki wrote:
>
> Hi,
>
> From the Ngxinx Lua API documentation:
>
> Do not use this directive and other content handler directives in
> the same location. For example, this directive and the proxy_pass
> <
http://wiki.nginx.org/HttpProxyModule#proxy_pass> directive should
>> send an email to
openresty-en...@googlegroups.com <javascript:>.
>> <
https://groups.google.com/d/optout>.
>
> --
> You received this message because you are subscribed to the Google
> Groups "openresty-en" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to
openresty-en...@googlegroups.com
> <mailto:
openresty-en...@googlegroups.com>.