You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2022/11/16 08:42:19 UTC

[GitHub] [apisix] Brucepower0223 opened a new issue, #8339: help request: plugins run,why step num is 2

Brucepower0223 opened a new issue, #8339:
URL: https://github.com/apache/apisix/issues/8339

   ### Description
   
      for i = 1, #plugins, 2 do
               local phase_func = plugins[i][phase]
               if phase_func then
                   plugin_run = true
                   local code, body = phase_func(plugins[i + 1], api_ctx)
                   if code or body then
                       if is_http then
                           if code >= 400 then
                               core.log.warn(plugins[i].name, " exits with http status code ", code)
                           end
   
                           core.response.exit(code, body)
                       else
                           if code >= 400 then
                               core.log.warn(plugins[i].name, " exits with status code ", code)
                           end
   
                           ngx_exit(1)
                       end
                   end
               end
           end
   
   note:   for i = 1, #plugins, 2   why the step num increase is 2?
   
   ### Environment
   
   - APISIX version (run `apisix version`):
   - Operating system (run `uname -a`):
   - OpenResty / Nginx version (run `openresty -V` or `nginx -V`):
   - etcd version, if relevant (run `curl http://127.0.0.1:9090/v1/server_info`):
   - APISIX Dashboard version, if relevant:
   - Plugin runner version, for issues related to plugin runners:
   - LuaRocks version, for installation issues (run `luarocks --version`):
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] Hazel6869 commented on issue #8339: help request: plugins run,why step num is 2

Posted by GitBox <gi...@apache.org>.
Hazel6869 commented on issue #8339:
URL: https://github.com/apache/apisix/issues/8339#issuecomment-1316702096

   @Brucepower0223 Hi,this is the case in the array [function pointer 1, parameter 1, function pointer 2, parameter 2]


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix] tzssangglass closed issue #8339: help request: plugins run,why step num is 2

Posted by GitBox <gi...@apache.org>.
tzssangglass closed issue #8339: help request: plugins run,why step num is 2
URL: https://github.com/apache/apisix/issues/8339


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org