Closed jsvisa closed 5 years ago
Add a config of HTTPAddress for the debugging purpose.
HTTPAddress
HTTPAddress: Specifying an HTTP port for debugging, currently used to dump DNS cache, and the request url is /cache, available query argument is nobody(boolean)
/cache
nobody
true(default): only get the cache size;
$ curl 127.0.0.1:5555/cache | jq { "length": 1, "capacity": 100, "body": {} }
false: get cache size along with cache detail.
$ curl 127.0.0.1:5555/cache?nobody=false | jq { "length": 1, "capacity": 100, "body": { "www.baidu.com. 1": [ { "name": "www.baidu.com.", "ttl": 1140, "type": "CNAME", "rdata": "www.a.shifen.com." }, { "name": "www.a.shifen.com.", "ttl": 300, "type": "CNAME", "rdata": "www.wshifen.com." }, { "name": "www.wshifen.com.", "ttl": 300, "type": "A", "rdata": "104.193.88.123" }, { "name": "www.wshifen.com.", "ttl": 300, "type": "A", "rdata": "104.193.88.77" } ] } }
Merged, thanks!
Add a config of
HTTPAddress
for the debugging purpose.HTTPAddress: Specifying an HTTP port for debugging, currently used to dump DNS cache, and the request url is
/cache
, available query argument isnobody
(boolean)true(default): only get the cache size;
false: get cache size along with cache detail.