Download the PHP package vinlon/laravel-sql-logger without Composer
On this page you can find all versions of the php package vinlon/laravel-sql-logger. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download vinlon/laravel-sql-logger
More information about vinlon/laravel-sql-logger
Files in vinlon/laravel-sql-logger
Download vinlon/laravel-sql-logger
More information about vinlon/laravel-sql-logger
Files in vinlon/laravel-sql-logger
Vendor vinlon
Package laravel-sql-logger
Short Description Log Sql Queries in Laravel framework
License MIT
Package laravel-sql-logger
Short Description Log Sql Queries in Laravel framework
License MIT
Please rate this library. Is it a good library?
Informations about the package laravel-sql-logger
Laravel Sql Logger
版本支持
- laravel 6.*
- laravel 7.*
使用方法
-
引入 package
-
发布config文件 (Laravel 版本 > 5.5)
先执行如下命令
然后选择 Provider: Vinlon\Laravel\SqlLogger\SqlLoggerProvider 对应的序号
在应用程序的config目录下,将生成sql-logger.php文件(注:一般情况下,此文件不需要做任何修改,配置的调整通过环境变量实现)
-
默认配置
安装完成后,默认同时开启All Query和Slow Query日志,使用logger中定义的默认channel. SQL执行时间超过 1 秒钟(1000ms) 会被定义为慢查询
-
配置建议
Log Channel示例 (config/logging.php)
TODO
- 单元测试
- 更多Laravel版本的测试与支持
参考
https://github.com/mnabialek/laravel-sql-logger https://github.com/overtrue/laravel-query-logger
All versions of laravel-sql-logger with dependencies
PHP Build Version
Package Version
Requires
laravel/framework Version
~6.0||~7.0||~8.0
The package vinlon/laravel-sql-logger contains the following files
Loading the files please wait ....