bzp2010 commented on code in PR #12563:
URL: https://github.com/apache/apisix/pull/12563#discussion_r2309616626
##########
apisix/plugins/ai-proxy-multi.lua:
##########
@@ -30,6 +30,7 @@ local ipairs = ipairs
local type = type
local priority_balancer = require("apisix.balancer.priority")
+local endpoint_regex = "^(https?)://([^:/]+):?(%d*)/?.*$"
Review Comment:
Are you sure this is correct?
1. The `/` appears to be unescaped. If the Lua string `"xxx"` can avoid this
issue, please disregard.
2. `%d` seems to cause backtracking and result in a failed match? Whereas
`\d` matches correctly.
I'm using https://regex101.com PCRE2 mode to check it.
--
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]