mirror of
https://github.com/midoks/mdserver-web.git
synced 2026-10-10 04:59:25 +08:00
Update webstats_common.lua
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
1. 单例模式:通过 getInstance() 获取全局唯一实例
|
||||
2. 共享内存:使用 ngx.shared.mw_total 作为日志缓存队列
|
||||
3. SQLite 数据库:每个站点独立一个数据库文件
|
||||
4. 定时任务:每 0.1 秒执行一次日志持久化
|
||||
4. 定时任务:每 0.5 秒执行一次日志持久化
|
||||
|
||||
主要数据流向:
|
||||
webstats_log.lua (日志采集) -> ngx.shared.mw_total (缓存队列) -> cron() (定时处理) -> SQLite (持久化)
|
||||
@@ -756,7 +756,7 @@ function _M.cron(self)
|
||||
end
|
||||
end
|
||||
|
||||
ngx.timer.every(0.1, timer_every_get_data_try)
|
||||
ngx.timer.every(0.5, timer_every_get_data_try)
|
||||
end
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user