shreemaan-abhishek commented on code in PR #13617:
URL: https://github.com/apache/apisix/pull/13617#discussion_r3489328231
##########
apisix/plugin.lua:
##########
@@ -1329,6 +1339,9 @@ function _M.run_plugin(phase, plugins, api_ctx)
run_meta_pre_function(conf, api_ctx, plugins[i]["name"])
plugin_run = true
api_ctx._plugin_name = plugins[i]["name"]
+ if api_ctx._skip_plugins and
api_ctx._skip_plugins[api_ctx._plugin_name] then
+ goto CONTINUE
+ end
Review Comment:
Good catch. Addressed in a62881902: the `_skip_plugins` check now runs right
after `meta_filter` and before
`run_meta_pre_function`/`_plugin_name`/`plugin_run` in both loops, so a skipped
action plugin no longer fires its meta pre_function or leaves stale state.
##########
apisix/plugin.lua:
##########
@@ -1367,12 +1380,17 @@ function _M.run_plugin(phase, plugins, api_ctx)
plugin_run = true
run_meta_pre_function(conf, api_ctx, plugins[i]["name"])
api_ctx._plugin_name = plugins[i]["name"]
+ if api_ctx._skip_plugins and
api_ctx._skip_plugins[api_ctx._plugin_name] then
+ goto CONTINUE
+ end
Review Comment:
Good catch. Addressed in a62881902: the `_skip_plugins` check now runs right
after `meta_filter` and before
`run_meta_pre_function`/`_plugin_name`/`plugin_run` in both loops, so a skipped
action plugin no longer fires its meta pre_function or leaves stale state.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]