Download the PHP package jose-chan/laravel-database-pool without Composer
On this page you can find all versions of the php package jose-chan/laravel-database-pool. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package laravel-database-pool
为了实现laravel+swoole协程实现的连接池
! 暂时不建议在pgsql、sqlite、sqlsrv环境中使用,因为仅测试过mysql连接
安装
! composer require jose-chan/laravel-database-pool
配置
config/database.php
文件中增加pool
配置项
``
使用
找到config/app.php
文件中的providers
配置,将Illuminate\Database\DatabaseServiceProvider::class
替换为JoseChan\Laravel\Database\Pool\Provider\PoolDatabaseServiceProvider::class
即可
``
代码使用
``
其他说明
-
该组建适用于laravel框架+swoole协程框架中,协程并发多个sql异步请求mysql,提高整体的执行效率,在非协程环境下,该组建将不会创建多个mysql连接
- 如果线程池中的所有连接都被借光了,则会抛出一个异常
All versions of laravel-database-pool with dependencies
PHP Build Version
Package Version
The package jose-chan/laravel-database-pool contains the following files
Loading the files please wait ....