(This page was automatically generated by the tools in the opsboy project on 03:17:25 31-May-2022 GMT.)

Detailed Test Report for lua-resty-core in linux x86_64 (hv)

Summary

Commit Testing Time Unexpected
Failures
Expected
Failures
Files Tests Elapsed Time
cf1aa0cb 2022-04-13 04:31:33 GMT 0 88 86 8951 1175 sec

LuaJIT

LuaJIT 2.1.0-beta3, commit 70f88773

OpenSSL

OpenSSL 1.1.1n 15 Mar 2022

Compilation Errors

Unexpected Failures

(none)

Expected Failures

File Name Details
errlog.t TEST 21: multi-line error log - response_body_like - response is expected (log lines: \#10 log level:6 log body:2022/04/13 08:27:01 [notice] 13709\#13709: start worker processes log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *32 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *33 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *34 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *35 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *36 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *37 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *38 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *39 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *40 client 127.0.0.1 closed keepalive connection) 'log lines: #10
log level:6
log body:2022/04/13 08:27:01 [notice] 13709#13709: start worker processes
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *32 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *33 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *34 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *35 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *36 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *37 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *38 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *39 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *40 client 127.0.0.1 closed keepalive connection
'
doesn't match '(?^s:\Alog lines: #1
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: -->
new line, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
\z)'
errlog.t TEST 21: multi-line error log - response_body_like - response is expected (log lines: \#10 log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *41 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *42 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *43 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *44 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *45 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *46 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *47 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *48 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *49 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:02 [info] 13766\#13766: *50 client 127.0.0.1 closed keepalive connection) 'log lines: #10
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *41 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *42 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *43 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *44 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *45 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *46 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *47 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *48 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *49 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:02 [info] 13766#13766: *50 client 127.0.0.1 closed keepalive connection
'
doesn't match '(?^s:\Alog lines: #1
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: -->
new line, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
\z)'
errlog.t TEST 18: flood the capturing buffer (5k) - response_body_like - response is expected (log lines: \#25 log level:4 log body:2022/04/13 08:27:04 [error] 13865\#13865: *127 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:04 [warn] 13865\#13865: *127 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:04 [error] 13865\#13865: *127 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:04 [error] 13865\#13865: *127 [lua] access_by_lua(nginx.conf:70):11: --> 99, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:04 [warn] 13865\#13865: *127 [lua] access_by_lua(nginx.conf:70):10: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:04 [error] 13865\#13865: *127 [lua] access_by_lua(nginx.conf:70):11: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost") 'log lines: #25
log level:4
log body:2022/04/13 08:27:04 [error] 13865#13865: *127 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:04 [warn] 13865#13865: *127 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:04 [error] 13865#13865: *127 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:04 [error] 13865#13865: *127 [lua] access_by_lua(nginx.conf:70):11: --> 99, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:04 [warn] 13865#13865: *127 [lua] access_by_lua(nginx.conf:70):10: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:04 [error] 13865#13865: *127 [lua] access_by_lua(nginx.conf:70):11: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
'
doesn't match '(?^s:\Alog lines: #26
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 99, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
\z)'
errlog.t TEST 18: flood the capturing buffer (5k) - response_body_like - response is expected (log lines: \#25 log level:4 log body:2022/04/13 08:27:04 [error] 13865\#13865: *128 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:04 [warn] 13865\#13865: *128 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:04 [error] 13865\#13865: *128 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:04 [error] 13865\#13865: *128 [lua] access_by_lua(nginx.conf:70):11: --> 99, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:04 [warn] 13865\#13865: *128 [lua] access_by_lua(nginx.conf:70):10: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:04 [error] 13865\#13865: *128 [lua] access_by_lua(nginx.conf:70):11: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost") 'log lines: #25
log level:4
log body:2022/04/13 08:27:04 [error] 13865#13865: *128 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:04 [warn] 13865#13865: *128 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:04 [error] 13865#13865: *128 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:04 [error] 13865#13865: *128 [lua] access_by_lua(nginx.conf:70):11: --> 99, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:04 [warn] 13865#13865: *128 [lua] access_by_lua(nginx.conf:70):10: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:04 [error] 13865#13865: *128 [lua] access_by_lua(nginx.conf:70):11: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
'
doesn't match '(?^s:\Alog lines: #26
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 99, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
\z)'
errlog.t TEST 22: user-supplied Lua table to hold the result (get one log + no log) - response_body_like - response is expected (maybe log lines: \#10 log level:6 log body:2022/04/13 08:27:06 [notice] 13709\#13709: start worker processes log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *209 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *210 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *211 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *212 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *213 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *214 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *215 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *216 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *217 client 127.0.0.1 closed keepalive connection end maybe log lines: \#10 log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *218 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *219 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *220 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *221 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *222 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *223 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *224 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *225 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *226 client 127.0.0.1 closed keepalive connection log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *227 client 127.0.0.1 closed keepalive connection end) 'maybe log lines: #10
log level:6
log body:2022/04/13 08:27:06 [notice] 13709#13709: start worker processes
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *209 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *210 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *211 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *212 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *213 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *214 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *215 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *216 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *217 client 127.0.0.1 closed keepalive connection
end
maybe log lines: #10
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *218 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *219 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *220 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *221 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *222 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *223 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *224 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *225 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *226 client 127.0.0.1 closed keepalive connection
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *227 client 127.0.0.1 closed keepalive connection
end
'
doesn't match '(?^s:\Amaybe log lines: #1
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: -->
new line, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
end
maybe log lines: #1
end
\z)'
errlog.t TEST 22: user-supplied Lua table to hold the result (get one log + no log) - response_body_like - response is expected (maybe log lines: \#3 log level:7 log body:2022/04/13 08:27:06 [info] 14003\#14003: *228 client 127.0.0.1 closed keepalive connection log level:4 log body:2022/04/13 08:27:06 [error] 14003\#14003: *229 [lua] access_by_lua(nginx.conf:66):8: --> new line, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:07 [error] 14003\#14003: *230 [lua] access_by_lua(nginx.conf:66):8: --> new line, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" end maybe log lines: \#3 end) 'maybe log lines: #3
log level:7
log body:2022/04/13 08:27:06 [info] 14003#14003: *228 client 127.0.0.1 closed keepalive connection
log level:4
log body:2022/04/13 08:27:06 [error] 14003#14003: *229 [lua] access_by_lua(nginx.conf:66):8: -->
new line, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:07 [error] 14003#14003: *230 [lua] access_by_lua(nginx.conf:66):8: -->
new line, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
end
maybe log lines: #3
end
'
doesn't match '(?^s:\Amaybe log lines: #1
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*access_by_lua\(nginx.conf:\d+\):\d+: -->
new line, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
end
maybe log lines: #1
end
\z)'
errlog.t TEST 31: ringbuf sentinel bug2 - response_body - response is expected (repeated req 0, req 0) @@ -1,2 +1,2 @@
log lines: \#18
-log lines: \#8
+log lines: \#1
'
errlog.t TEST 31: ringbuf sentinel bug2 - response_body - response is expected (repeated req 1, req 0) @@ -1,2 +1,2 @@
log lines: \#18
-log lines: \#8
+log lines: \#9
'
errlog.t nginx: [emerg] invalid capture error log size "3k", minimum size is 4096 in /home/ec2-user/git/lua-resty-core/t/servroot/conf/nginx.conf:25
errlog.t TEST 12: filter log by level(ngx.WARN) - response_body - response is expected (repeated req 0, req 0) got: 'log lines:3
'
expected: 'log lines:2
'
errlog.t TEST 11: filter log by level(ngx.INFO) - response_body - response is expected (repeated req 0, req 0) got: 'log lines:10
'
expected: 'log lines:3
'
errlog.t TEST 11: filter log by level(ngx.INFO) - response_body - response is expected (repeated req 1, req 0) got: 'log lines:10
'
expected: 'log lines:3
'
errlog.t TEST 30: ringbuf sentinel bug1 - response_body - response is expected (repeated req 0, req 0) @@ -1,3 +1,3 @@
log lines: \#2
-AAA
+aaa
aaa
'
errlog.t TEST 13: filter log by level(ngx.CRIT) - response_body - response is expected (repeated req 0, req 0) got: 'log lines:10
'
expected: 'log lines:0
'
errlog.t TEST 13: filter log by level(ngx.CRIT) - response_body - response is expected (repeated req 1, req 0) got: 'log lines:10
'
expected: 'log lines:0
'
errlog.t nginx: [emerg] invalid number of arguments in "lua_capture_error_log" directive in /home/ec2-user/git/lua-resty-core/t/servroot/conf/nginx.conf:25
errlog.t TEST 20: fetch a few and generate a few, then fetch again (not overflown again) - response_body_like - response is expected (msg count: 3 log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *78 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:18 [warn] 14350\#14350: *78 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *78 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" msg count: 3 log level:5 log body:2022/04/13 08:27:18 [warn] 14350\#14350: *78 [lua] access_by_lua(nginx.conf:70):10: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *78 [lua] access_by_lua(nginx.conf:70):11: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:18 [warn] 14350\#14350: *78 [lua] access_by_lua(nginx.conf:70):10: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *78 [lua] access_by_lua(nginx.conf:70):11: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *78 [lua] content_by_lua(nginx.conf:102):13: howdy, something new!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *78 [lua] content_by_lua(nginx.conf:102):14: howdy, something even newer!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost") 'msg count: 3
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *78 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:18 [warn] 14350#14350: *78 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *78 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
msg count: 3
log level:5
log body:2022/04/13 08:27:18 [warn] 14350#14350: *78 [lua] access_by_lua(nginx.conf:70):10: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *78 [lua] access_by_lua(nginx.conf:70):11: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:18 [warn] 14350#14350: *78 [lua] access_by_lua(nginx.conf:70):10: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *78 [lua] access_by_lua(nginx.conf:70):11: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *78 [lua] content_by_lua(nginx.conf:102):13: howdy, something new!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *78 [lua] content_by_lua(nginx.conf:102):14: howdy, something even newer!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
'
doesn't match '(?^s:\Amsg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
msg count: 3
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: howdy, something new!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: howdy, something even newer!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
\z)'
errlog.t TEST 20: fetch a few and generate a few, then fetch again (not overflown again) - response_body_like - response is expected (msg count: 3 log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *79 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:18 [warn] 14350\#14350: *79 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *79 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" msg count: 3 log level:5 log body:2022/04/13 08:27:18 [warn] 14350\#14350: *79 [lua] access_by_lua(nginx.conf:70):10: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *79 [lua] access_by_lua(nginx.conf:70):11: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:18 [warn] 14350\#14350: *79 [lua] access_by_lua(nginx.conf:70):10: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *79 [lua] access_by_lua(nginx.conf:70):11: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *79 [lua] content_by_lua(nginx.conf:102):13: howdy, something new!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:18 [error] 14350\#14350: *79 [lua] content_by_lua(nginx.conf:102):14: howdy, something even newer!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost") 'msg count: 3
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *79 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:18 [warn] 14350#14350: *79 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *79 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
msg count: 3
log level:5
log body:2022/04/13 08:27:18 [warn] 14350#14350: *79 [lua] access_by_lua(nginx.conf:70):10: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *79 [lua] access_by_lua(nginx.conf:70):11: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:18 [warn] 14350#14350: *79 [lua] access_by_lua(nginx.conf:70):10: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *79 [lua] access_by_lua(nginx.conf:70):11: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *79 [lua] content_by_lua(nginx.conf:102):13: howdy, something new!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:18 [error] 14350#14350: *79 [lua] content_by_lua(nginx.conf:102):14: howdy, something even newer!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
'
doesn't match '(?^s:\Amsg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
msg count: 3
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: howdy, something new!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: howdy, something even newer!, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
\z)'
errlog.t TEST 19: fetch a few and generate a few, then fetch again (overflown again) - response_body_like - response is expected (msg count: 3 log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *179 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:21 [warn] 14485\#14485: *179 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *179 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" msg count: 3 log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *179 [lua] access_by_lua(nginx.conf:70):11: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:21 [warn] 14485\#14485: *179 [lua] access_by_lua(nginx.conf:70):10: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *179 [lua] access_by_lua(nginx.conf:70):11: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *179 [lua] content_by_lua(nginx.conf:104):14: --> 102, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *179 [lua] content_by_lua(nginx.conf:104):15: --> 103, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *179 [lua] content_by_lua(nginx.conf:104):16: --> 104, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost") 'msg count: 3
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *179 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:21 [warn] 14485#14485: *179 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *179 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
msg count: 3
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *179 [lua] access_by_lua(nginx.conf:70):11: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:21 [warn] 14485#14485: *179 [lua] access_by_lua(nginx.conf:70):10: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *179 [lua] access_by_lua(nginx.conf:70):11: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *179 [lua] content_by_lua(nginx.conf:104):14: --> 102, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *179 [lua] content_by_lua(nginx.conf:104):15: --> 103, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *179 [lua] content_by_lua(nginx.conf:104):16: --> 104, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
'
doesn't match '(?^s:\Amsg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
msg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 102, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 103, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 104, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
\z)'
errlog.t TEST 19: fetch a few and generate a few, then fetch again (overflown again) - response_body_like - response is expected (msg count: 3 log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *180 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:21 [warn] 14485\#14485: *180 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *180 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" msg count: 3 log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *180 [lua] access_by_lua(nginx.conf:70):11: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:5 log body:2022/04/13 08:27:21 [warn] 14485\#14485: *180 [lua] access_by_lua(nginx.conf:70):10: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *180 [lua] access_by_lua(nginx.conf:70):11: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *180 [lua] content_by_lua(nginx.conf:104):14: --> 102, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *180 [lua] content_by_lua(nginx.conf:104):15: --> 103, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost" log level:4 log body:2022/04/13 08:27:21 [error] 14485\#14485: *180 [lua] content_by_lua(nginx.conf:104):16: --> 104, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost") 'msg count: 3
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *180 [lua] access_by_lua(nginx.conf:70):11: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:21 [warn] 14485#14485: *180 [lua] access_by_lua(nginx.conf:70):10: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *180 [lua] access_by_lua(nginx.conf:70):11: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
msg count: 3
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *180 [lua] access_by_lua(nginx.conf:70):11: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:2022/04/13 08:27:21 [warn] 14485#14485: *180 [lua] access_by_lua(nginx.conf:70):10: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *180 [lua] access_by_lua(nginx.conf:70):11: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *180 [lua] content_by_lua(nginx.conf:104):14: --> 102, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *180 [lua] content_by_lua(nginx.conf:104):15: --> 103, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:2022/04/13 08:27:21 [error] 14485#14485: *180 [lua] content_by_lua(nginx.conf:104):16: --> 104, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
'
doesn't match '(?^s:\Amsg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 89, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
msg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 90, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?access_by_lua\(nginx.conf:\d+\):\d+: --> 91, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 102, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 103, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 104, client: 127.0.0.1, server: localhost, request: "GET /t HTTP/1.1", host: "localhost"
\z)'
process-type-hup.t TEST 1: sanity - pattern "init_worker_by_lua:6: process type: privileged" should match a line in error.log (req 0) Looks like you failed 1 test of 8.
process-type-privileged-agent-connections.t nginx: [error] [lua] init_by_lua:5: enable_privileged_agent failed: bad 'connections' argument: number expected and greater than 0
process-type-single.t TEST 1: sanity - response_body - response is expected (repeated req 0, req 0) got: "process type: worker\x{0a}"
length: 21
expected: "process type: single\x{0a}"
length: 21
strings begin to differ at char 15 (line 1 column 15)
process-type-single.t TEST 1: sanity - grep_error_log_out (req 0) '[TRACE 1 init_by_lua:18 loop]
[TRACE 2 init_worker_by_lua:4 loop]
[TRACE 2 content_by_lua(nginx.conf:84):4 loop]
process type in init_by_lua*: master
init_worker_by_lua:10: process type: worker
'
doesn't match '(?^:\[TRACE\s+\d+ init_by_lua:\d+ loop\]
\[TRACE\s+\d+ init_worker_by_lua:\d+ loop\]
\[TRACE\s+\d+ content_by_lua\(nginx.conf:\d+\):4 loop\]
process type in init_by_lua\*: single
init_worker_by_lua:10: process type: single
)'
process-type-single.t TEST 1: sanity - response_body - response is expected (repeated req 1, req 0) got: "process type: worker\x{0a}"
length: 21
expected: "process type: single\x{0a}"
length: 21
strings begin to differ at char 15 (line 1 column 15)
process-type-single.t TEST 1: sanity - grep_error_log_out (req 1) '[TRACE 1 init_by_lua:18 loop]
[TRACE 2 init_worker_by_lua:4 loop]
[TRACE 2 content_by_lua(nginx.conf:84):4 loop]
process type in init_by_lua*: master
init_worker_by_lua:10: process type: worker
'
doesn't match '(?^:\[TRACE\s+\d+ init_by_lua:\d+ loop\]
\[TRACE\s+\d+ init_worker_by_lua:\d+ loop\]
\[TRACE\s+\d+ content_by_lua\(nginx.conf:\d+\):4 loop\]
process type in init_by_lua\*: single
init_worker_by_lua:10: process type: single
)'
request.t TEST 2: ngx.req.get_headers (raw) - pattern "(?^:\[TRACE\s+\d+ .*? -> \d+\])" should match a line in error.log (req 0)
request.t TEST 2: ngx.req.get_headers (raw) - pattern "(?^:\[TRACE\s+\d+ .*? -> \d+\])" should match a line in error.log (req 1)
request.t TEST 7: ngx.req.start_time() - response_body - response is expected (repeated req 0, req 0) got: "true\x{0a}>= 0.099: true\x{0a}< 0.11: false\x{0a}"
length: 34
expected: "true\x{0a}>= 0.099: true\x{0a}< 0.11: true\x{0a}"
length: 33
strings begin to differ at char 29 (line 3 column 9)
semaphore.t TEST 28: kill a thread that is waiting on another thread that is waiting on semaphore - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:34:46 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:34:46 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:34:46 [debug] 27830\#27830: *401 event timer add: 0: 1000:14664241
2022/04/13 08:34:46 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:34:46 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:34:46 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:34:46 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:34:46 [debug] 27830\#27830: worker cycle
'
semaphore.t TEST 11: semaphore in access_by_lua (all allowed) - grep_error_log_out (req 0) @@ -1,2 +1,3 @@
sem: timeout,
+sem: timeout,
sem: 1,
'
semaphore.t TEST 15: semaphore in body_filter_by_lua (wait not allowed) - grep_error_log_out (req 0) @@ -1,3 +1,5 @@
+sem: timeout,
+sem: 6 times,
sem: 1,
sem: API disabled in the context of body_filter_by_lua*,
sem: 1,
'
semaphore.t TEST 32: semaphore wait time is zero - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:34:51 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:34:51 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:34:51 [debug] 27830\#27830: *401 event timer add: 0: 1000:14669243
2022/04/13 08:34:51 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:34:51 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:34:51 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:34:51 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:34:51 [debug] 27830\#27830: worker cycle
2022/04/13 08:34:51 [debug] 27830\#27830: epoll timer: 1000
2022/04/13 08:34:51 [debug] 28040\#28040: epoll: fd:6 ev:0001 d:0000000008DC8A10
'
semaphore.t TEST 21: semaphore post in header_filter_by_lua (subrequest) - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:34:52 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:34:52 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:34:52 [debug] 27830\#27830: *401 event timer add: 0: 1000:14670244
2022/04/13 08:34:52 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:34:52 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:34:52 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:34:52 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:34:52 [debug] 27830\#27830: worker cycle
2022/04/13 08:34:52 [debug] 27830\#27830: epoll timer: 1000
2022/04/13 08:34:52 [debug] 28118\#28118: *612 writev: 168 of 168
'
semaphore.t TEST 1: basic semaphore in uthread - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:34:53 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:34:53 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:34:53 [debug] 27830\#27830: *401 event timer add: 0: 1000:14671244
2022/04/13 08:34:53 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:34:53 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:34:53 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:34:53 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:34:53 [debug] 27830\#27830: worker cycle
2022/04/13 08:34:53 [debug] 27830\#27830: epoll timer: 1000
2022/04/13 08:34:53 [debug] 28148\#28148: timer delta: 73
'
semaphore.t TEST 8: semaphore in init_worker_by_lua (new and post) - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:34:54 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:34:54 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:34:54 [debug] 27830\#27830: *401 event timer add: 0: 1000:14672244
2022/04/13 08:34:54 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:34:54 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:34:54 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:34:54 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:34:54 [debug] 27830\#27830: worker cycle
2022/04/13 08:34:54 [debug] 27830\#27830: epoll timer: 1000
2022/04/13 08:34:54 [notice] 27280\#27280: signal 1 (SIGHUP) received from 28216, reconfiguring
'
semaphore.t TEST 27: kill a light thread that is waiting on a semaphore (after post) - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:34:56 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:34:56 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:34:56 [debug] 27830\#27830: *401 event timer add: 0: 1000:14674245
2022/04/13 08:34:56 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:34:56 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:34:56 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:34:56 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:34:56 [debug] 27830\#27830: worker cycle
2022/04/13 08:34:56 [debug] 27830\#27830: epoll timer: 1000
2022/04/13 08:34:56 [debug] 28292\#28292: epoll: fd:6 ev:0001 d:0000000008DC8A10
'
semaphore.t TEST 24: semaphore post in timer.at - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:34:57 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:34:57 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:34:57 [debug] 27830\#27830: *401 event timer add: 0: 1000:14675246
2022/04/13 08:34:57 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:34:57 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:34:57 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:34:57 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:34:57 [debug] 27830\#27830: worker cycle
'
semaphore.t TEST 25: two thread wait for each other - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:34:58 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:34:58 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:34:58 [debug] 27830\#27830: *401 event timer add: 0: 1000:14676246
2022/04/13 08:34:58 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:34:58 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:34:58 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:34:58 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:34:58 [debug] 27830\#27830: worker cycle
2022/04/13 08:34:58 [debug] 27830\#27830: epoll timer: 1000
2022/04/13 08:34:58 [debug] 27280\#27280: malloc: 00000000088E84A0:2048
'
semaphore.t TEST 4: basic semaphore in subrequest - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:35:01 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 1) 2022/04/13 08:35:01 [error] 27830\#27830: *401 [lua] init_worker_by_lua:18: sem: 6 times, context: ngx.timer
2022/04/13 08:35:01 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:35:01 [debug] 27830\#27830: *401 event timer add: 0: 1000:14679247
2022/04/13 08:35:01 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:35:01 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:35:01 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:35:01 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:35:01 [debug] 27830\#27830: worker cycle
2022/04/13 08:35:01 [debug] 27830\#27830: epoll timer: 1000
'
semaphore.t TEST 4: basic semaphore in subrequest - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:35:01 [error] 27830\#27830: *401 [lua] init_worker_by_lua:18: sem: 6 times, context: ngx.timer" (req 1) 2022/04/13 08:35:01 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:35:01 [debug] 27830\#27830: *401 event timer add: 0: 1000:14679247
2022/04/13 08:35:01 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:35:01 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:35:01 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:35:01 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:35:01 [debug] 27830\#27830: worker cycle
2022/04/13 08:35:01 [debug] 27830\#27830: epoll timer: 1000
2022/04/13 08:35:01 [debug] 28466\#28466: epoll: fd:6 ev:0001 d:00000000084F7120
'
semaphore.t TEST 13: semaphore in log_by_lua (wait not allowed) - grep_error_log_out (req 1) @@ -1,2 +1,3 @@
sem: 1 while logging request,
sem: API disabled in the context of log_by_lua* while logging request,
+sem: timeout,
'
semaphore.t TEST 40: bugfix: semaphore instance can't be garbage collected when someone is waiting on it - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:35:03 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:35:03 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:35:03 [debug] 27830\#27830: *401 event timer add: 0: 1000:14681247
2022/04/13 08:35:03 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:35:03 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:35:03 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:35:03 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:35:03 [debug] 27830\#27830: worker cycle
2022/04/13 08:35:03 [debug] 27830\#27830: epoll timer: 1000
2022/04/13 08:35:03 [notice] 27280\#27280: signal 1 (SIGHUP) received from 28570, reconfiguring
'
semaphore.t TEST 30: main thread wait a light thread that is waiting on a semaphore - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:35:04 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:35:04 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:35:04 [debug] 27830\#27830: *401 event timer add: 0: 1000:14682247
2022/04/13 08:35:04 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:35:04 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:35:04 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:35:04 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:35:04 [debug] 27830\#27830: worker cycle
2022/04/13 08:35:04 [debug] 27830\#27830: epoll timer: 1000
2022/04/13 08:35:04 [debug] 28574\#28574: epoll: fd:6 ev:0001 d:0000000009045240
'
semaphore.t TEST 18: semaphore wait post in access_by_lua - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:35:05 [error] 27830\#27830: *401 [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:35:05 [debug] 27830\#27830: http lua semaphore wait: 0000000009B803F8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:35:05 [debug] 27830\#27830: *401 event timer add: 0: 1000:14683247
2022/04/13 08:35:05 [debug] 27830\#27830: http lua semaphore wait yielding
2022/04/13 08:35:05 [debug] 27830\#27830: *401 lua resume returned 1
2022/04/13 08:35:05 [debug] 27830\#27830: *401 lua thread yielded
2022/04/13 08:35:05 [debug] 27830\#27830: *401 lua run thread returned -2
2022/04/13 08:35:05 [debug] 27830\#27830: worker cycle
2022/04/13 08:35:05 [debug] 27830\#27830: epoll timer: 1000
2022/04/13 08:35:05 [debug] 28646\#28646: *1007 http header: "Host: Test-Nginx"
'
stream/errlog.t TEST 18: flood the capturing buffer (5k) - response_body_like - response is expected (log lines: \#32 log level:5 log body:2022/04/13 08:38:55 [warn] 2510\#2510: *153 stream [lua] content_by_lua(nginx.conf:78):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:55 [error] 2510\#2510: *153 stream [lua] content_by_lua(nginx.conf:78):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:38:55 [warn] 2510\#2510: *153 stream [lua] content_by_lua(nginx.conf:78):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:55 [error] 2510\#2510: *153 stream [lua] content_by_lua(nginx.conf:78):11: --> 99, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:38:55 [warn] 2510\#2510: *153 stream [lua] content_by_lua(nginx.conf:78):10: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:55 [error] 2510\#2510: *153 stream [lua] content_by_lua(nginx.conf:78):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985) 'log lines: #32
log level:5
log body:2022/04/13 08:38:55 [warn] 2510#2510: *153 stream [lua] content_by_lua(nginx.conf:78):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:55 [error] 2510#2510: *153 stream [lua] content_by_lua(nginx.conf:78):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:38:55 [warn] 2510#2510: *153 stream [lua] content_by_lua(nginx.conf:78):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:55 [error] 2510#2510: *153 stream [lua] content_by_lua(nginx.conf:78):11: --> 99, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:38:55 [warn] 2510#2510: *153 stream [lua] content_by_lua(nginx.conf:78):10: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:55 [error] 2510#2510: *153 stream [lua] content_by_lua(nginx.conf:78):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985
'
doesn't match '(?^s:\A(?:log lines: #33
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 84, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 99, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: 0.0.0.0:\d+
)\z)'
stream/errlog.t TEST 18: flood the capturing buffer (5k) - response_body_like - response is expected (log lines: \#32 log level:5 log body:2022/04/13 08:38:56 [warn] 2510\#2510: *156 stream [lua] content_by_lua(nginx.conf:78):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:56 [error] 2510\#2510: *156 stream [lua] content_by_lua(nginx.conf:78):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:38:56 [warn] 2510\#2510: *156 stream [lua] content_by_lua(nginx.conf:78):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:56 [error] 2510\#2510: *156 stream [lua] content_by_lua(nginx.conf:78):11: --> 99, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:38:56 [warn] 2510\#2510: *156 stream [lua] content_by_lua(nginx.conf:78):10: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:56 [error] 2510\#2510: *156 stream [lua] content_by_lua(nginx.conf:78):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985) 'log lines: #32
log level:5
log body:2022/04/13 08:38:56 [warn] 2510#2510: *156 stream [lua] content_by_lua(nginx.conf:78):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:56 [error] 2510#2510: *156 stream [lua] content_by_lua(nginx.conf:78):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:38:56 [warn] 2510#2510: *156 stream [lua] content_by_lua(nginx.conf:78):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:56 [error] 2510#2510: *156 stream [lua] content_by_lua(nginx.conf:78):11: --> 99, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:38:56 [warn] 2510#2510: *156 stream [lua] content_by_lua(nginx.conf:78):10: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:56 [error] 2510#2510: *156 stream [lua] content_by_lua(nginx.conf:78):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985
'
doesn't match '(?^s:\A(?:log lines: #33
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 84, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 99, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: 0.0.0.0:\d+
)\z)'
stream/errlog.t TEST 20: fetch a few and generate a few, then fetch again (not overflown again) - response_body_like - response is expected (msg count: 3 log level:5 log body:2022/04/13 08:38:58 [warn] 2656\#2656: *273 stream [lua] content_by_lua(nginx.conf:91):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:58 [error] 2656\#2656: *273 stream [lua] content_by_lua(nginx.conf:91):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:38:58 [warn] 2656\#2656: *273 stream [lua] content_by_lua(nginx.conf:91):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985 msg count: 3 log level:4 log body:2022/04/13 08:38:58 [error] 2656\#2656: *273 stream [lua] content_by_lua(nginx.conf:91):11: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:38:58 [warn] 2656\#2656: *273 stream [lua] content_by_lua(nginx.conf:91):10: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:58 [error] 2656\#2656: *273 stream [lua] content_by_lua(nginx.conf:91):11: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:58 [error] 2656\#2656: *273 stream [lua] content_by_lua(nginx.conf:91):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:58 [error] 2656\#2656: *273 stream [lua] content_by_lua(nginx.conf:91):23: howdy, something new!, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:58 [error] 2656\#2656: *273 stream [lua] content_by_lua(nginx.conf:91):24: howdy, something even newer!, client: 127.0.0.1, server: 0.0.0.0:1985) 'msg count: 3
log level:5
log body:2022/04/13 08:38:58 [warn] 2656#2656: *273 stream [lua] content_by_lua(nginx.conf:91):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:58 [error] 2656#2656: *273 stream [lua] content_by_lua(nginx.conf:91):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:38:58 [warn] 2656#2656: *273 stream [lua] content_by_lua(nginx.conf:91):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985
msg count: 3
log level:4
log body:2022/04/13 08:38:58 [error] 2656#2656: *273 stream [lua] content_by_lua(nginx.conf:91):11: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:38:58 [warn] 2656#2656: *273 stream [lua] content_by_lua(nginx.conf:91):10: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:58 [error] 2656#2656: *273 stream [lua] content_by_lua(nginx.conf:91):11: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:58 [error] 2656#2656: *273 stream [lua] content_by_lua(nginx.conf:91):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:58 [error] 2656#2656: *273 stream [lua] content_by_lua(nginx.conf:91):23: howdy, something new!, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:58 [error] 2656#2656: *273 stream [lua] content_by_lua(nginx.conf:91):24: howdy, something even newer!, client: 127.0.0.1, server: 0.0.0.0:1985
'
doesn't match '(?^s:\Amsg count: 3
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 84, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
msg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 86, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 86, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 87, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: howdy, something new!, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: howdy, something even newer!, client: 127.0.0.1, server: 0.0.0.0:\d+
\z)'
stream/errlog.t TEST 20: fetch a few and generate a few, then fetch again (not overflown again) - response_body_like - response is expected (msg count: 3 log level:5 log body:2022/04/13 08:38:59 [warn] 2656\#2656: *276 stream [lua] content_by_lua(nginx.conf:91):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:59 [error] 2656\#2656: *276 stream [lua] content_by_lua(nginx.conf:91):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:38:59 [warn] 2656\#2656: *276 stream [lua] content_by_lua(nginx.conf:91):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985 msg count: 3 log level:4 log body:2022/04/13 08:38:59 [error] 2656\#2656: *276 stream [lua] content_by_lua(nginx.conf:91):11: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:38:59 [warn] 2656\#2656: *276 stream [lua] content_by_lua(nginx.conf:91):10: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:59 [error] 2656\#2656: *276 stream [lua] content_by_lua(nginx.conf:91):11: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:59 [error] 2656\#2656: *276 stream [lua] content_by_lua(nginx.conf:91):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:59 [error] 2656\#2656: *276 stream [lua] content_by_lua(nginx.conf:91):23: howdy, something new!, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:38:59 [error] 2656\#2656: *276 stream [lua] content_by_lua(nginx.conf:91):24: howdy, something even newer!, client: 127.0.0.1, server: 0.0.0.0:1985) 'msg count: 3
log level:5
log body:2022/04/13 08:38:59 [warn] 2656#2656: *276 stream [lua] content_by_lua(nginx.conf:91):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:59 [error] 2656#2656: *276 stream [lua] content_by_lua(nginx.conf:91):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:38:59 [warn] 2656#2656: *276 stream [lua] content_by_lua(nginx.conf:91):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985
msg count: 3
log level:4
log body:2022/04/13 08:38:59 [error] 2656#2656: *276 stream [lua] content_by_lua(nginx.conf:91):11: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:38:59 [warn] 2656#2656: *276 stream [lua] content_by_lua(nginx.conf:91):10: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:59 [error] 2656#2656: *276 stream [lua] content_by_lua(nginx.conf:91):11: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:59 [error] 2656#2656: *276 stream [lua] content_by_lua(nginx.conf:91):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:59 [error] 2656#2656: *276 stream [lua] content_by_lua(nginx.conf:91):23: howdy, something new!, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:38:59 [error] 2656#2656: *276 stream [lua] content_by_lua(nginx.conf:91):24: howdy, something even newer!, client: 127.0.0.1, server: 0.0.0.0:1985
'
doesn't match '(?^s:\Amsg count: 3
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 84, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
msg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 86, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 86, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 87, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: howdy, something new!, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: howdy, something even newer!, client: 127.0.0.1, server: 0.0.0.0:\d+
\z)'
stream/errlog.t TEST 11: filter log by level(ngx.INFO) - response_body - response is expected (repeated req 0, req 0) got: 'log lines:4
'
expected: 'log lines:3
'
stream/errlog.t TEST 17: flood the capturing buffer (4k) - response_body_like - response is expected (log lines: \#25 log level:4 log body:2022/04/13 08:39:00 [error] 2728\#2728: *333 stream [lua] content_by_lua(nginx.conf:78):11: --> 88, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:39:00 [warn] 2728\#2728: *333 stream [lua] content_by_lua(nginx.conf:78):10: --> 89, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:00 [error] 2728\#2728: *333 stream [lua] content_by_lua(nginx.conf:78):11: --> 89, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:00 [error] 2728\#2728: *333 stream [lua] content_by_lua(nginx.conf:78):11: --> 99, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:39:00 [warn] 2728\#2728: *333 stream [lua] content_by_lua(nginx.conf:78):10: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:00 [error] 2728\#2728: *333 stream [lua] content_by_lua(nginx.conf:78):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985) 'log lines: #25
log level:4
log body:2022/04/13 08:39:00 [error] 2728#2728: *333 stream [lua] content_by_lua(nginx.conf:78):11: --> 88, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:39:00 [warn] 2728#2728: *333 stream [lua] content_by_lua(nginx.conf:78):10: --> 89, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:00 [error] 2728#2728: *333 stream [lua] content_by_lua(nginx.conf:78):11: --> 89, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:00 [error] 2728#2728: *333 stream [lua] content_by_lua(nginx.conf:78):11: --> 99, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:39:00 [warn] 2728#2728: *333 stream [lua] content_by_lua(nginx.conf:78):10: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:00 [error] 2728#2728: *333 stream [lua] content_by_lua(nginx.conf:78):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985
'
doesn't match '(?^s:\A(?:log lines: #26
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 89, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 99, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: 0.0.0.0:\d+
)\z)'
stream/errlog.t TEST 17: flood the capturing buffer (4k) - response_body_like - response is expected (log lines: \#25 log level:4 log body:2022/04/13 08:39:01 [error] 2728\#2728: *336 stream [lua] content_by_lua(nginx.conf:78):11: --> 88, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:39:01 [warn] 2728\#2728: *336 stream [lua] content_by_lua(nginx.conf:78):10: --> 89, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:01 [error] 2728\#2728: *336 stream [lua] content_by_lua(nginx.conf:78):11: --> 89, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:01 [error] 2728\#2728: *336 stream [lua] content_by_lua(nginx.conf:78):11: --> 99, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:39:01 [warn] 2728\#2728: *336 stream [lua] content_by_lua(nginx.conf:78):10: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:01 [error] 2728\#2728: *336 stream [lua] content_by_lua(nginx.conf:78):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985) 'log lines: #25
log level:4
log body:2022/04/13 08:39:01 [error] 2728#2728: *336 stream [lua] content_by_lua(nginx.conf:78):11: --> 88, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:39:01 [warn] 2728#2728: *336 stream [lua] content_by_lua(nginx.conf:78):10: --> 89, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:01 [error] 2728#2728: *336 stream [lua] content_by_lua(nginx.conf:78):11: --> 89, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:01 [error] 2728#2728: *336 stream [lua] content_by_lua(nginx.conf:78):11: --> 99, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:39:01 [warn] 2728#2728: *336 stream [lua] content_by_lua(nginx.conf:78):10: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:01 [error] 2728#2728: *336 stream [lua] content_by_lua(nginx.conf:78):11: --> 100, client: 127.0.0.1, server: 0.0.0.0:1985
'
doesn't match '(?^s:\A(?:log lines: #26
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 89, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 99, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: --> 100, client: 127.0.0.1, server: 0.0.0.0:\d+
)\z)'
stream/errlog.t nginx: [emerg] invalid capture error log size "3k", minimum size is 4096 in /home/ec2-user/git/lua-resty-core/t/servroot/conf/nginx.conf:17
stream/errlog.t TEST 12: filter log by level(ngx.WARN) - response_body - response is expected (repeated req 0, req 0) got: 'log lines:3
'
expected: 'log lines:2
'
stream/errlog.t nginx: [emerg] invalid number of arguments in "lua_capture_error_log" directive in /home/ec2-user/git/lua-resty-core/t/servroot/conf/nginx.conf:17
stream/errlog.t TEST 19: fetch a few and generate a few, then fetch again (overflown again) - response_body_like - response is expected (msg count: 3 log level:5 log body:2022/04/13 08:39:07 [warn] 2861\#2861: *3 stream [lua] content_by_lua(nginx.conf:93):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:07 [error] 2861\#2861: *3 stream [lua] content_by_lua(nginx.conf:93):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:39:07 [warn] 2861\#2861: *3 stream [lua] content_by_lua(nginx.conf:93):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985 msg count: 3 log level:5 log body:2022/04/13 08:39:07 [warn] 2861\#2861: *3 stream [lua] content_by_lua(nginx.conf:93):10: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:07 [error] 2861\#2861: *3 stream [lua] content_by_lua(nginx.conf:93):11: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:39:07 [warn] 2861\#2861: *3 stream [lua] content_by_lua(nginx.conf:93):10: --> 88, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:07 [error] 2861\#2861: *3 stream [lua] content_by_lua(nginx.conf:93):24: --> 102, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:07 [error] 2861\#2861: *3 stream [lua] content_by_lua(nginx.conf:93):25: --> 103, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:07 [error] 2861\#2861: *3 stream [lua] content_by_lua(nginx.conf:93):26: --> 104, client: 127.0.0.1, server: 0.0.0.0:1985) 'msg count: 3
log level:5
log body:2022/04/13 08:39:07 [warn] 2861#2861: *3 stream [lua] content_by_lua(nginx.conf:93):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:07 [error] 2861#2861: *3 stream [lua] content_by_lua(nginx.conf:93):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:39:07 [warn] 2861#2861: *3 stream [lua] content_by_lua(nginx.conf:93):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985
msg count: 3
log level:5
log body:2022/04/13 08:39:07 [warn] 2861#2861: *3 stream [lua] content_by_lua(nginx.conf:93):10: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:07 [error] 2861#2861: *3 stream [lua] content_by_lua(nginx.conf:93):11: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:39:07 [warn] 2861#2861: *3 stream [lua] content_by_lua(nginx.conf:93):10: --> 88, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:07 [error] 2861#2861: *3 stream [lua] content_by_lua(nginx.conf:93):24: --> 102, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:07 [error] 2861#2861: *3 stream [lua] content_by_lua(nginx.conf:93):25: --> 103, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:07 [error] 2861#2861: *3 stream [lua] content_by_lua(nginx.conf:93):26: --> 104, client: 127.0.0.1, server: 0.0.0.0:1985
'
doesn't match '(?^s:\Amsg count: 3
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 84, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
msg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 86, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 86, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 87, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 102, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 103, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 104, client: 127.0.0.1, server: 0.0.0.0:\d+
|msg count: 3
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 84, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
msg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 87, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 87, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 102, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 103, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 104, client: 127.0.0.1, server: 0.0.0.0:\d+
\z)'
stream/errlog.t TEST 19: fetch a few and generate a few, then fetch again (overflown again) - response_body_like - response is expected (msg count: 3 log level:5 log body:2022/04/13 08:39:07 [warn] 2861\#2861: *6 stream [lua] content_by_lua(nginx.conf:93):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:07 [error] 2861\#2861: *6 stream [lua] content_by_lua(nginx.conf:93):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:39:07 [warn] 2861\#2861: *6 stream [lua] content_by_lua(nginx.conf:93):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985 msg count: 3 log level:5 log body:2022/04/13 08:39:07 [warn] 2861\#2861: *6 stream [lua] content_by_lua(nginx.conf:93):10: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:07 [error] 2861\#2861: *6 stream [lua] content_by_lua(nginx.conf:93):11: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985 log level:5 log body:2022/04/13 08:39:07 [warn] 2861\#2861: *6 stream [lua] content_by_lua(nginx.conf:93):10: --> 88, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:07 [error] 2861\#2861: *6 stream [lua] content_by_lua(nginx.conf:93):24: --> 102, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:07 [error] 2861\#2861: *6 stream [lua] content_by_lua(nginx.conf:93):25: --> 103, client: 127.0.0.1, server: 0.0.0.0:1985 log level:4 log body:2022/04/13 08:39:07 [error] 2861\#2861: *6 stream [lua] content_by_lua(nginx.conf:93):26: --> 104, client: 127.0.0.1, server: 0.0.0.0:1985) 'msg count: 3
log level:5
log body:2022/04/13 08:39:07 [warn] 2861#2861: *6 stream [lua] content_by_lua(nginx.conf:93):10: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:07 [error] 2861#2861: *6 stream [lua] content_by_lua(nginx.conf:93):11: --> 85, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:39:07 [warn] 2861#2861: *6 stream [lua] content_by_lua(nginx.conf:93):10: --> 86, client: 127.0.0.1, server: 0.0.0.0:1985
msg count: 3
log level:5
log body:2022/04/13 08:39:07 [warn] 2861#2861: *6 stream [lua] content_by_lua(nginx.conf:93):10: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:07 [error] 2861#2861: *6 stream [lua] content_by_lua(nginx.conf:93):11: --> 87, client: 127.0.0.1, server: 0.0.0.0:1985
log level:5
log body:2022/04/13 08:39:07 [warn] 2861#2861: *6 stream [lua] content_by_lua(nginx.conf:93):10: --> 88, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:07 [error] 2861#2861: *6 stream [lua] content_by_lua(nginx.conf:93):24: --> 102, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:07 [error] 2861#2861: *6 stream [lua] content_by_lua(nginx.conf:93):25: --> 103, client: 127.0.0.1, server: 0.0.0.0:1985
log level:4
log body:2022/04/13 08:39:07 [error] 2861#2861: *6 stream [lua] content_by_lua(nginx.conf:93):26: --> 104, client: 127.0.0.1, server: 0.0.0.0:1985
'
doesn't match '(?^s:\Amsg count: 3
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 84, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
msg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 86, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 86, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 87, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 102, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 103, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 104, client: 127.0.0.1, server: 0.0.0.0:\d+
|msg count: 3
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 84, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 85, client: 127.0.0.1, server: 0.0.0.0:\d+
msg count: 3
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 87, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 87, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:5
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[warn\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 88, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 102, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 103, client: 127.0.0.1, server: 0.0.0.0:\d+
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*?content_by_lua\(nginx.conf:\d+\):\d+: --> 104, client: 127.0.0.1, server: 0.0.0.0:\d+
\z)'
stream/errlog.t TEST 3: client connected info - grep_error_log_out (req 0) 'client 127.0.0.1:40546 connected to
capture log line:10
'
doesn't match '(?^:^client .*? connected to .*?
capture log line:1
$)'
stream/errlog.t TEST 3: client connected info - grep_error_log_out (req 1) 'client 127.0.0.1:40550 connected to
capture log line:10
'
doesn't match '(?^:^client .*? connected to .*?
capture log line:2
$)'
stream/errlog.t TEST 22: user-supplied Lua table to hold the result (get one log + no log) - response_body_like - response is expected (maybe log lines: \#2 log level:6 log body:2022/04/13 08:39:09 [notice] 2854\#2854: start worker processes log level:4 log body:2022/04/13 08:39:10 [error] 2948\#2948: *93 stream [lua] content_by_lua(nginx.conf:75):8: --> new line, client: 127.0.0.1, server: 0.0.0.0:1985 end maybe log lines: \#2 end) 'maybe log lines: #2
log level:6
log body:2022/04/13 08:39:09 [notice] 2854#2854: start worker processes
log level:4
log body:2022/04/13 08:39:10 [error] 2948#2948: *93 stream [lua] content_by_lua(nginx.conf:75):8: -->
new line, client: 127.0.0.1, server: 0.0.0.0:1985
end
maybe log lines: #2
end
'
doesn't match '(?^s:\Amaybe log lines: #1
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: -->
new line, client: 127.0.0.1, server: 0.0.0.0:\d+
end
maybe log lines: #1
end
\z)'
stream/errlog.t TEST 13: filter log by level(ngx.CRIT) - response_body - response is expected (repeated req 0, req 0) got: 'log lines:1
'
expected: 'log lines:0
'
stream/errlog.t TEST 21: multi-line error log - response_body_like - response is expected (log lines: \#2 log level:6 log body:2022/04/13 08:39:11 [notice] 2854\#2854: start worker processes log level:4 log body:2022/04/13 08:39:11 [error] 3014\#3014: *153 stream [lua] content_by_lua(nginx.conf:67):8: --> new line, client: 127.0.0.1, server: 0.0.0.0:1985) 'log lines: #2
log level:6
log body:2022/04/13 08:39:11 [notice] 2854#2854: start worker processes
log level:4
log body:2022/04/13 08:39:11 [error] 3014#3014: *153 stream [lua] content_by_lua(nginx.conf:67):8: -->
new line, client: 127.0.0.1, server: 0.0.0.0:1985
'
doesn't match '(?^s:\Alog lines: #1
log level:4
log body:\d{4}/\d{2}/\d{2} \d{2}:\d{2}:\d{2} \[error\] (\d+).*content_by_lua\(nginx.conf:\d+\):\d+: -->
new line, client: 127.0.0.1, server: 0.0.0.0:\d+
\z)'
stream/process-type-hup.t TEST 1: sanity - pattern "init_worker_by_lua:6: process type: privileged" should match a line in error.log (req 0) Looks like you failed 1 test of 8.
stream/process-type-single.t TEST 1: sanity - response_body - response is expected (repeated req 0, req 0) got: "process type: worker\x{0a}"
length: 21
expected: "process type: single\x{0a}"
length: 21
strings begin to differ at char 15 (line 1 column 15)
stream/process-type-single.t TEST 1: sanity - grep_error_log_out (req 0) '[TRACE 1 init_by_lua:31 loop]
[TRACE 2 init_worker_by_lua:4 loop]
[TRACE 2 content_by_lua(nginx.conf:78):4 loop]
process type in init_by_lua*: master
init_worker_by_lua:10: process type: worker
'
doesn't match '(?^:\[TRACE\s+\d+ init_by_lua:\d+ loop\]
\[TRACE\s+\d+ init_worker_by_lua:\d+ loop\]
\[TRACE\s+\d+ content_by_lua\(nginx.conf:\d+\):4 loop\]
process type in init_by_lua\*: single
init_worker_by_lua:10: process type: single
)'
stream/process-type-single.t TEST 1: sanity - response_body - response is expected (repeated req 1, req 0) got: "process type: worker\x{0a}"
length: 21
expected: "process type: single\x{0a}"
length: 21
strings begin to differ at char 15 (line 1 column 15)
stream/process-type-single.t TEST 1: sanity - grep_error_log_out (req 1) '[TRACE 1 init_by_lua:31 loop]
[TRACE 2 init_worker_by_lua:4 loop]
[TRACE 2 content_by_lua(nginx.conf:78):4 loop]
process type in init_by_lua*: master
init_worker_by_lua:10: process type: worker
'
doesn't match '(?^:\[TRACE\s+\d+ init_by_lua:\d+ loop\]
\[TRACE\s+\d+ init_worker_by_lua:\d+ loop\]
\[TRACE\s+\d+ content_by_lua\(nginx.conf:\d+\):4 loop\]
process type in init_by_lua\*: single
init_worker_by_lua:10: process type: single
)'
stream/request.t TEST 1: ngx.req.start_time() - response_body - response is expected (repeated req 0, req 0) @@ -1,3 +1,3 @@
true
>= 0.099: true
-< 0.11: true
+< 0.11: false
'
Looks like you failed 1 test of 12.
stream/semaphore.t TEST 1: basic semaphore in uthread - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:02 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:02 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:18: sem: 3 times, context: ngx.timer
2022/04/13 08:42:02 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:02 [debug] 7505\#7505: *42 event timer add: 0: 1000:15100058
2022/04/13 08:42:02 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:02 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:02 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:02 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:02 [debug] 7505\#7505: worker cycle
2022/04/13 08:42:02 [debug] 7505\#7505: epoll timer: 1000
'
stream/semaphore.t TEST 1: basic semaphore in uthread - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:02 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:18: sem: 3 times, context: ngx.timer" (req 0) 2022/04/13 08:42:02 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:02 [debug] 7505\#7505: *42 event timer add: 0: 1000:15100058
2022/04/13 08:42:02 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:02 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:02 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:02 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:02 [debug] 7505\#7505: worker cycle
2022/04/13 08:42:02 [debug] 7505\#7505: epoll timer: 1000
2022/04/13 08:42:01 [debug] 7649\#7649: malloc: 000000000907F200:24
'
stream/semaphore.t TEST 17: kill a light thread that is waiting on a semaphore (after post) - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:03 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:03 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:03 [debug] 7505\#7505: *42 event timer add: 0: 1000:15101058
2022/04/13 08:42:03 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:03 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:03 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:03 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:03 [debug] 7505\#7505: worker cycle
2022/04/13 08:42:03 [debug] 7505\#7505: epoll timer: 1000
2022/04/13 08:42:03 [debug] 7685\#7685: epoll: fd:7 ev:0001 d:0000000008FAFE70
'
stream/semaphore.t TEST 13: semaphore wait post in preread_by_lua - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:04 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:04 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:04 [debug] 7505\#7505: *42 event timer add: 0: 1000:15102059
2022/04/13 08:42:04 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:04 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:04 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:04 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:04 [debug] 7505\#7505: worker cycle
2022/04/13 08:42:04 [debug] 7505\#7505: epoll timer: 1000
2022/04/13 08:42:04 [debug] 7718\#7718: epoll: fd:7 ev:0001 d:0000000009503470
'
stream/semaphore.t TEST 3: semaphore wait time=0 - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:05 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:05 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:18: sem: 3 times, context: ngx.timer
2022/04/13 08:42:05 [debug] 7751\#7751: *275 lua light thread ended normally
2022/04/13 08:42:05 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:05 [debug] 7505\#7505: *42 event timer add: 0: 1000:15103059
2022/04/13 08:42:05 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:05 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:05 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:05 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:05 [debug] 7505\#7505: worker cycle
'
stream/semaphore.t TEST 3: semaphore wait time=0 - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:05 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:18: sem: 3 times, context: ngx.timer" (req 0) 2022/04/13 08:42:05 [debug] 7751\#7751: *275 lua light thread ended normally
2022/04/13 08:42:05 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:05 [debug] 7505\#7505: *42 event timer add: 0: 1000:15103059
2022/04/13 08:42:05 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:05 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:05 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:05 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:05 [debug] 7505\#7505: worker cycle
2022/04/13 08:42:05 [debug] 7505\#7505: epoll timer: 1000
'
stream/semaphore.t TEST 2: semaphore wait order - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:07 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:07 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:07 [debug] 7505\#7505: *42 event timer add: 0: 1000:15105060
2022/04/13 08:42:07 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:07 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:07 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:07 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:07 [debug] 7505\#7505: worker cycle
2022/04/13 08:42:07 [debug] 7505\#7505: epoll timer: 1000
2022/04/13 08:42:06 [debug] 7446\#7446: malloc: 00000000091EF2A0:2048
'
stream/semaphore.t TEST 9: semaphore in content_by_lua (all allowed) - grep_error_log_out (req 0) @@ -1,2 +1,4 @@
sem: timeout,
+sem: 3 times,
+sem: timeout,
sem: 1,
'
stream/semaphore.t TEST 28: basic semaphore count - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:10 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:10 [debug] 7446\#7446: malloc: 0000000008AAACA0:4
2022/04/13 08:42:10 [debug] 7446\#7446: malloc: 0000000008AAF690:16
2022/04/13 08:42:10 [debug] 7446\#7446: malloc: 0000000008A947C0:64
2022/04/13 08:42:10 [debug] 7446\#7446: malloc: 0000000008AB60B0:16
2022/04/13 08:42:10 [debug] 7446\#7446: malloc: 0000000008AC2B80:56
2022/04/13 08:42:10 [debug] 7446\#7446: malloc: 0000000008AC2D60:16
2022/04/13 08:42:10 [debug] 7446\#7446: malloc: 0000000008AC26F0:12
2022/04/13 08:42:10 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:10 [debug] 7446\#7446: malloc: 00000000085C4E20:16
'
stream/semaphore.t TEST 20: main thread wait a light thread that is waiting on a semaphore - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:12 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:12 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:12 [debug] 7505\#7505: *42 event timer add: 0: 1000:15110062
2022/04/13 08:42:12 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:12 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:12 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:12 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:12 [debug] 7505\#7505: worker cycle
2022/04/13 08:42:12 [debug] 7505\#7505: epoll timer: 1000
2022/04/13 08:42:11 [debug] 7446\#7446: malloc: 00000000086ECB10:2048
'
stream/semaphore.t TEST 7: semaphore in init_worker_by_lua (new and post) - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:15 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:15 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:15 [debug] 7505\#7505: *42 event timer add: 0: 1000:15113064
2022/04/13 08:42:15 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:15 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:15 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:15 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:15 [debug] 7505\#7505: worker cycle
2022/04/13 08:42:15 [debug] 7505\#7505: epoll timer: 1000
2022/04/13 08:42:15 [debug] 7446\#7446: malloc: 000000000906C410:24
'
stream/semaphore.t TEST 16: kill a light thread that is waiting on a semaphore (no resource) - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:16 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:16 [debug] 7446\#7446: malloc: 00000000095FB6C0:16
2022/04/13 08:42:16 [debug] 7446\#7446: malloc: 00000000095FB710:15
2022/04/13 08:42:16 [debug] 7446\#7446: malloc: 00000000095FB760:16
2022/04/13 08:42:16 [debug] 7446\#7446: malloc: 0000000009853B60:56
2022/04/13 08:42:16 [debug] 7446\#7446: malloc: 0000000009853BE0:16
2022/04/13 08:42:16 [debug] 7446\#7446: malloc: 0000000009BB1F70:21
2022/04/13 08:42:16 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:16 [debug] 7446\#7446: malloc: 0000000009BB1FD0:16
2022/04/13 08:42:16 [debug] 7505\#7505: *42 event timer add: 0: 1000:15114064
'
stream/semaphore.t TEST 11: semaphore in ngx.timer (all allowed) - grep_error_log_out (req 0) @@ -1,2 +1,3 @@
sem: timeout,
+sem: timeout,
sem: 1,
'
stream/semaphore.t TEST 15: two thread wait for each other - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:19 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:19 [debug] 8249\#8249: *709 free: 000000000904F660, unused: 0
2022/04/13 08:42:19 [debug] 8249\#8249: *709 free: 00000000097024F0
2022/04/13 08:42:19 [debug] 8249\#8249: *709 hc free: 0000000000000000
2022/04/13 08:42:19 [debug] 8249\#8249: *709 hc busy: 0000000000000000 0
2022/04/13 08:42:19 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:19 [debug] 8249\#8249: *709 tcp_nodelay
2022/04/13 08:42:19 [debug] 7505\#7505: *42 event timer add: 0: 1000:15117065
2022/04/13 08:42:19 [debug] 8249\#8249: *709 reusable connection: 1
2022/04/13 08:42:19 [debug] 7505\#7505: stream lua semaphore wait yielding
'
stream/semaphore.t TEST 18: kill a thread that is waiting on another thread that is waiting on semaphore - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:20 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:20 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:18: sem: 3 times, context: ngx.timer
2022/04/13 08:42:20 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:20 [debug] 7505\#7505: *42 event timer add: 0: 1000:15118065
2022/04/13 08:42:20 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:20 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:20 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:20 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:20 [debug] 7505\#7505: worker cycle
2022/04/13 08:42:20 [debug] 7505\#7505: epoll timer: 1000
'
stream/semaphore.t TEST 18: kill a thread that is waiting on another thread that is waiting on semaphore - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:20 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:18: sem: 3 times, context: ngx.timer" (req 0) 2022/04/13 08:42:20 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:20 [debug] 7505\#7505: *42 event timer add: 0: 1000:15118065
2022/04/13 08:42:20 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:20 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:20 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:20 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:20 [debug] 7505\#7505: worker cycle
2022/04/13 08:42:20 [debug] 7505\#7505: epoll timer: 1000
2022/04/13 08:42:19 [debug] 7446\#7446: child: 0 7505 e:1 t:0 d:0 r:1 j:0
'
stream/semaphore.t TEST 10: semaphore in log_by_lua (wait not allowed) - grep_error_log_out (req 0) @@ -1,2 +1,3 @@
+sem: timeout,
sem: 1 while returning text,
sem: API disabled in the context of log_by_lua* while returning text,
'
stream/semaphore.t TEST 29: basic semaphore count (negative number) - pattern "[error]" should not match any line in error.log but matches line "2022/04/13 08:42:25 [error] 7505\#7505: *42 stream [lua] init_worker_by_lua:14: sem: timeout, context: ngx.timer" (req 0) 2022/04/13 08:42:25 [debug] 7505\#7505: stream lua semaphore wait: 00000000094EC6D8, timeout: 1000, resources: 0, event posted: 0
2022/04/13 08:42:25 [debug] 7505\#7505: *42 event timer add: 0: 1000:15123068
2022/04/13 08:42:25 [debug] 7505\#7505: stream lua semaphore wait yielding
2022/04/13 08:42:25 [debug] 7505\#7505: *42 lua resume returned 1
2022/04/13 08:42:25 [debug] 7505\#7505: *42 lua thread yielded
2022/04/13 08:42:25 [debug] 7505\#7505: *42 lua run thread returned -2
2022/04/13 08:42:25 [debug] 7505\#7505: worker cycle
2022/04/13 08:42:25 [debug] 7505\#7505: epoll timer: 1000
2022/04/13 08:42:25 [debug] 8471\#8471: epoll: fd:7 ev:0001 d:00000000084BBD50
'
stream/time.t TEST 1: ngx.now() - response_body - response is expected (repeated req 0, req 0) @@ -1,3 +1,3 @@
true
>= 0.099: true
-< 0.11: true
+< 0.11: false
'
time.t TEST 1: ngx.now() - response_body - response is expected (repeated req 0, req 0) @@ -1,3 +1,3 @@
true
>= 0.099: true
-< 0.11: true
+< 0.11: false
'

Warnings

Go back to the index page.