Wauux commented on issue #4941:
URL: https://github.com/apache/apisix/issues/4941#issuecomment-908873157


   > Could you provide the logs before the stack overflow?
   
   这条连接的日志 dns每变化一次,deepcopy 就会增加一层递归拷贝.. 持续一段时间后就会出现栈溢出
   
   2021/08/30 09:52:15 [error] 10780#10780: *35662 [lua] debug.lua:128: 
http_access_phase(): call require("apisix").http_access_phase() args:{}, 
client: 192.168.33.133, server: _, request: "GET / HTTP/1.1", host: 
"192.168.33.133:9080"
   2021/08/30 09:52:15 [info] 10780#10780: *35662 [lua] radixtree.lua:488: 
compare_param(): pcre pat: \/((.|\n)*), client: 192.168.33.133, server: _, 
request: "GET / HTTP/1.1", host: "192.168.33.133:9080"
   2021/08/30 09:52:15 [warn] 10780#10780: *35662 [lua] json.lua:82: failed to 
encode: Cannot serialise, excessive nesting (1001) force: true, client: 
192.168.33.133, server: _, request: "GET / HTTP/1.1", host: 
"192.168.33.133:9080"
   2021/08/30 09:52:15 [warn] 10780#10780: *35662 [lua] json.lua:82: failed to 
encode: Cannot serialise, excessive nesting (1001) force: true, client: 
192.168.33.133, server: _, request: "GET / HTTP/1.1", host: 
"192.168.33.133:9080"
   2021/08/30 09:52:15 [info] 10780#10780: *35662 [lua] init.lua:387: 
fun_org(): matched route: , client: 192.168.33.133, server: _, request: "GET / 
HTTP/1.1", host: "192.168.33.133:9080"
   2021/08/30 09:52:15 [info] 10780#10780: *35662 [lua] client.lua:124: 
dns_parse(): dns resolve www.test.com, result: 
{"address":"192.168.33.101","ttl":0,"name":"www.test.com","class":1,"type":1,"section":1},
 client: 192.168.33.133, server: _, request: "GET / HTTP/1.1", host: 
"192.168.33.133:9080"
   2021/08/30 09:52:15 [info] 10780#10780: *35662 [lua] resolver.lua:39: 
parse_domain(): parse addr: 
{"address":"192.168.33.101","name":"www.test.com","class":1,"ttl":0,"type":1,"section":1},
 client: 192.168.33.133, server: _, request: "GET / HTTP/1.1", host: 
"192.168.33.133:9080"
   2021/08/30 09:52:15 [info] 10780#10780: *35662 [lua] resolver.lua:40: 
parse_domain(): resolver: ["127.0.0.1"], client: 192.168.33.133, server: _, 
request: "GET / HTTP/1.1", host: "192.168.33.133:9080"
   2021/08/30 09:52:15 [info] 10780#10780: *35662 [lua] resolver.lua:41: 
parse_domain(): host: www.test.com, client: 192.168.33.133, server: _, request: 
"GET / HTTP/1.1", host: "192.168.33.133:9080"
   2021/08/30 09:52:15 [info] 10780#10780: *35662 [lua] resolver.lua:43: 
parse_domain(): dns resolver domain: www.test.com to 192.168.33.101, client: 
192.168.33.133, server: _, request: "GET / HTTP/1.1", host: 
"192.168.33.133:9080"
   2021/08/30 09:52:15 [error] 10780#10780: *35662 lua entry thread aborted: 
runtime error: stack overflow
   2021/08/30 09:52:15 [error] 10780#10780: *35662 [lua] debug.lua:128: 
http_header_filter_phase(): call require("apisix").http_header_filter_phase() 
args:{} while sending response to client, client: 192.168.33.133, server: _, 
request: "GET / HTTP/1.1", host: "192.168.33.133:9080"
   2021/08/30 09:52:15 [error] 10780#10780: *35662 [lua] debug.lua:134: 
http_header_filter_phase(): call require("apisix").http_header_filter_phase() 
return:{} while sending response to client, client: 192.168.33.133, server: _, 
request: "GET / HTTP/1.1", host: "192.168.33.133:9080"
   2021/08/30 09:52:15 [error] 10780#10780: *35662 [lua] debug.lua:128: 
http_log_phase(): call require("apisix").http_log_phase() args:{} while logging 
request, client: 192.168.33.133, server: _, request: "GET / HTTP/1.1", host: 
"192.168.33.133:9080"
   2021/08/30 09:52:15 [error] 10780#10780: *35662 [lua] debug.lua:134: 
http_log_phase(): call require("apisix").http_log_phase() return:{} while 
logging request, client: 192.168.33.133, server: _, request: "GET / HTTP/1.1", 
host: "192.168.33.133:9080"


-- 
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]


Reply via email to