Update webstats_common.lua

This commit is contained in:
midoks
2023-03-10 13:19:58 +08:00
parent 65649d171d
commit 02048c3265
+4 -3
View File
@@ -528,10 +528,8 @@ function _M.store_logs_line(self, db, stmt, input_sn, info)
local request_headers = logline["request_headers"]
local excluded = logline["excluded"]
-- self:D("json:"..json.encode(logline))
local time_key = logline["time_key"]
if not excluded then
stmt:bind_names {
time=time,
ip=ip,
@@ -553,13 +551,16 @@ function _M.store_logs_line(self, db, stmt, input_sn, info)
local res, err = stmt:step()
if tostring(res) == "5" then
self:D("json:"..json.encode(logline))
self:D("step res:"..tostring(res) ..",step err:"..tostring(err))
self:D("the step database connection is busy, so it will be stored later.")
if stmt then
stmt:reset()
end
return false
end
stmt:reset()
end
return true
end