webman/log记录不到请求日志,包括客户端ip,方法、地址、POST数据、SQL等。
刚开始的时候还能记录一些报错日志的,后来干脆什么都不记录了。请问是什么原因导致的?
[2024-02-23 15:44:16] default.ERROR: 127.0.0.1 GET 127.0.0.1:8787/app/ai/user/info
PDOException: SQLSTATE[HY000] [2002] 由于目标计算机积极拒绝,无法连接。
return [
'enable' => true,
'exception' => [
// 是否记录异常到日志
'enable' => true,
// 不会记录到日志的异常类
'dontReport' => [
support\exception\BusinessException::class
]
],
'dontReport' => [
'app' => [
],
'controller' => [
],
'action' => [
],
'path' => [
]
]
];
"require": {
"php": ">=7.2",
"workerman/webman-framework": "^1.5.0",
"monolog/monolog": "^2.0",
"webman/admin": "^0.6.18",
"yansongda/pay": "^3.0.0",
"webman/console": "^1.2",
"illuminate/redis": "^8.83",
"illuminate/events": "^8.83",
"webman/cors": "^1.0",
"webman/log": "^1.1"
},
估计你把它禁用了吧,config/plugin/webman/log/app.php 里enable改成true
没有禁用,都是默认的配置.