mirror of
https://github.com/midoks/mdserver-web.git
synced 2026-10-18 23:45:52 +08:00
Update webstats_common.lua
This commit is contained in:
@@ -36,9 +36,6 @@ function _M.new(self)
|
|||||||
params = nil,
|
params = nil,
|
||||||
site_config = nil,
|
site_config = nil,
|
||||||
config = nil,
|
config = nil,
|
||||||
cron_num = 0,
|
|
||||||
cron_num_limit = 4,
|
|
||||||
|
|
||||||
}
|
}
|
||||||
-- self.dbs = {}
|
-- self.dbs = {}
|
||||||
return setmetatable(self, mt)
|
return setmetatable(self, mt)
|
||||||
@@ -256,12 +253,6 @@ end
|
|||||||
|
|
||||||
-- 后台任务
|
-- 后台任务
|
||||||
function _M.cron(self)
|
function _M.cron(self)
|
||||||
self.cron_num = self.cron_num + 1
|
|
||||||
if self.cron_num > self.cron_num_limit then
|
|
||||||
return
|
|
||||||
end
|
|
||||||
|
|
||||||
-- self:D("PID:"..tostring(ngx.worker.id())..",cron_num:"..tostring(self.cron_num))
|
|
||||||
|
|
||||||
local timer_every_get_data = function (premature)
|
local timer_every_get_data = function (premature)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user