boxunphp/mysql

PHP Mysql Client

Installs: 11

Dependents: 1

Suggesters: 0

Security: 0

Stars: 1

Watchers: 1

Forks: 0

Open Issues: 0

pkg:composer/boxunphp/mysql

v2.1.2 2021-10-08 11:52 UTC

This package is auto-updated.

Last update: 2025-10-09 12:03:41 UTC


README

PHP Mysql Client

Configure

$config = [
    'master' => [
        'host' => 'mysql-3306',
        'port' => 3306,
        'username' => 'root',
        'password' => '123456',
        'dbname' => 'test',
        'charset' => 'utf8',
    ],
    'slaves' => [
        [
            'host' => 'mysql-3307',
            'port' => 3307,
            'username' => 'root',
            'password' => '123456',
            'dbname' => 'test',
            'charset' => 'utf8',
        ],
        [
            'host' => 'mysql-3308',
            'port' => 3308,
            'username' => 'root',
            'password' => '123456',
            'dbname' => 'test',
            'charset' => 'utf8',
        ],
    ],
    'connect_timeout' => 1,
    'timeout' => 1,
    'is_persistent' => true,
];