Skip to content

Commit 16e5f28

Browse files
committed
设置动态加载监听方法
1 parent 8862a45 commit 16e5f28

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ Zanehy\SqlMonitor\SqlMonitorServiceProvider::class,
2929
1. 配置 `env``APP_ENV``local`
3030
2. 配置 `env``APP_DEBUG``true`
3131
3. 新增 `env` 的配置 `MONITOR``true` (该种方式主要是为了兼容前两种配置在生产环境下需单独开启sql监听模式增加的一种独立开关配置)
32-
32+
4. 增加 `env` 的配置 `MONITOR_ACTIONS` 为要监控的方法(模糊匹配,多个监控的方法以 `|` 隔开即可,案例: `MONITOR_ACTIONS=test|monitor` 监听链接中带 `test``monitor` 的方法)
33+
3334
- 日志打印和输出,日志字段解释
3435
* action: 当前访问的页面或者接口地址,以 `sql_monitor_action:` 为前缀
3536
* sql:当前方法执行的sql语句 使用 `?` 作为占位符

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "zanehy/laravel-sql-monitor",
3-
"description": "laravel moniro sql exec",
3+
"description": "SQL monitoring in laravel production environment",
44
"license": "MIT",
55
"authors": [
66
{

0 commit comments

Comments
 (0)