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 2021/09/08 01:45:02 UTC

[GitHub] [apisix] spacewander commented on a change in pull request #5011: [WIP] add new dump config api for control api

spacewander commented on a change in pull request #5011:
URL: https://github.com/apache/apisix/pull/5011#discussion_r703958988



##########
File path: apisix/control/v1.lua
##########
@@ -189,4 +212,10 @@ return {
         uris = {"/gc"},
         handler = _M.trigger_gc,
     },
+    -- /v1/dump

Review comment:
       Please use restful like API names for dump specific resources, like `/v1/upstreams/xxx` and `/v1/upstreams`.

##########
File path: apisix/control/v1.lua
##########
@@ -156,6 +157,28 @@ function _M.get_health_checker()
     return 200, info
 end
 
+local function iter_add_get_routes_info(infos, values)
+    local temp_infos = {}
+    for _, route in core.config_util.iterate_values(values) do
+        local new_route = copy.deepcopy(route)

Review comment:
       We already have `core.table.deepcopy`




-- 
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: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org