tokers commented on a change in pull request #4019:
URL: https://github.com/apache/apisix/pull/4019#discussion_r610500138
##########
File path: apisix/plugins/traffic-split.lua
##########
@@ -247,9 +244,15 @@ function _M.access(conf, ctx)
return
end
- local weighted_upstreams, match_flag
+ local weighted_upstreams
+ local match_flag = true
+
for _, rule in ipairs(conf.rules) do
- match_flag = true
+ if not rule.match then
Review comment:
Better to add descriptions to document that when match is absent, the
rule is unconditional.
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]