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 2020/12/04 01:08:09 UTC

[GitHub] [apisix] tzssangglass commented on a change in pull request #2943: feat: support enable/disable route

tzssangglass commented on a change in pull request #2943:
URL: https://github.com/apache/apisix/pull/2943#discussion_r535760947



##########
File path: apisix/http/router/radixtree_host_uri.lua
##########
@@ -94,7 +94,14 @@ local function create_radixtree_router(routes)
     host_router = nil
 
     for _, route in ipairs(routes or {}) do
+        local status = core.table.try_read_attr(route, "value", "status")
+        if status and status ~= 1 then

Review comment:
       just follow this
   https://github.com/apache/apisix/blob/9e3c34a0103b88d340285017e34021cbc1f0fde8/apisix/schema_def.lua#L630-L635




----------------------------------------------------------------
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:
users@infra.apache.org