-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(router) new router support and tests fix #8938
Conversation
local router = setmetatable({ | ||
schema = s, | ||
router = inst, | ||
routes = {}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we use table.new
to pre-allocate table?
515515d
to
f4869a0
Compare
.requirements
Outdated
@@ -9,5 +9,5 @@ RESTY_PCRE_VERSION=8.45 | |||
RESTY_LMDB_VERSION=master | |||
RESTY_EVENTS_VERSION=0.1.1 | |||
LIBYAML_VERSION=0.2.5 | |||
KONG_BUILD_TOOLS_VERSION=4.30.0 | |||
KONG_BUILD_TOOLS_VERSION=feat/atc_router_build |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
change it to official version before merge
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this could be 4.32.3
or 4.33
.
|
||
|
||
local function is_regex_magic(path) | ||
return sub(path, 1, 1) == "~" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It may be replaced with OP_REGEX
below?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to add ATC to .requirement
.
Also, we need to add libatc_router.so
to dyn lib search path (cpath).
Update: It's my local build's problem. I manually installed the ATC library on the wrong path.
And, maybe we need to update developer.md
about passing ATC's version to build script.
We aslo need to add an entry in |
|
||
local c = context.new(self.schema) | ||
|
||
for _, field in ipairs(self.fields) do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it seems headers are the only variables that we fetch lazily. Could we just unconditionally add all other fields here?
Most tests working, still fixing a few leftover ones