# mysql-async **Repository Path**: flyzyh/mysql-async ## Basic Information - **Project Name**: mysql-async - **Description**: mysql-async 是基于 swoole 开发的 PHP 异步 MySQL 客户端,内置连接池和任务排队机制。基于 mysql-async 可以编写出纯异步、支持超高并发的 PHP 应用。 - **Primary Language**: Unknown - **License**: Apache-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2015-05-18 - **Last Updated**: 2024-06-16 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # mysql-async Async mysql client for PHP. Install ----- 1. compile swoole with --enable-async-mysql 2. git clone https://github.com/swoole/mysql-async Usage ---- ```php $config = array( 'host' => '127.0.0.1', 'user' => 'root', 'password' => 'root', 'database' => 'test', ); $pool = new Swoole\Async\MySQL($config, 100); for($i = 0; $i < 10000; $i++) { $pool->query("show tables", function($mysqli, mysqli_result $result){ var_dump($result->fetch_all()); }); } ```