数据表:
uni-stat-pages:有数据
uni-stat-page-logs:有数据
uni-stat-page-result:无数据
云函数:
uni-stat-receiver:有日志
uni-stat-cron:有日志,但是感觉不大正常
uni-stat-cron日志如下:
请求入参: {
"args": {
"userPayload": "",
"triggerTime": "2024-06-01T08:20:00Z",
"triggerName": "TIMER_LATEST"
},
"requestId": "timer1717230001962-533f0b3f-eb1e-4064-be22-54d5778b8e92"
}
[uni-stat-cron/timer1717230001962-533f0b3f-eb1e-4064-be22-54d5778b8e92/28ms/DEBUG] Cron start time: 2024-06-01 16:20:02
[uni-stat-cron/timer1717230001962-533f0b3f-eb1e-4064-be22-54d5778b8e92/28ms/DEBUG] Cron end time: 2024-06-01 16:20:02
请求响应状态: success
配置:
uni-config-center/uni-stat/config.js
已开启了:cronMin
{
"debug": false,
"redis": false,
"cachetime": 604800,
"sessionExpireTime": 1800,
"realtimeStat": true,
"cronMin": true,
"cronMinTips": "如果设置cronMin: true(开启分钟级统计)则你必须再修改 cloudfunctions/uni-stat-cron/package.json 文件内的 triggers 属性的 config的值为 0 */10 * * * * * 代表每10分钟运行一次定时任务",
"pageDetailStat": false,
}
uni-stat-cron/package.json
定时器每10分钟运行一次。
{
"name": "uni-stat-cron",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC",
"dependencies": {
"uni-stat": "file:../common/uni-stat"
},
"cloudfunction-config": {
"concurrency": 1,
"memorySize": 512,
"timeout": 600,
"triggers": [
{
"name": "uni-stat-cron",
"type": "timer",
"config": "0 */10 * * * * *"
}
]
},
"extensions": {}
}
个人感觉配置是没问题了,奈何页面数据还是零蛋。已经在社区搜索了相关问题,无法解决,只能发帖,求管理员帮忙看下,谢谢。
1***@qq.com (作者)
页面统计有数据了,但是内容统计还没有,我在群里问你好了。
2024-06-04 09:52
DCloud_云服务_JRP
回复 1***@qq.com: 好的
2024-06-04 12:10