Sample config for round-robin mysql read server

1

1864com

Guest
Member
Hello, from these posts:

XF2 features a new "ReplicationAdapter" which allows separate read and write connections to be made.

You can see a typical example of configuration below:
PHP:

Code:

Code:
$config['db']['adapterClass'] = 'XF\Db\Mysqli\ReplicationAdapter';
$config['db']['write'] = [
'host' => '192.168.10.1',
// ... username, password, dbname etc.
];
$config['db']['read'] = [
'host' => '192.168.10.2',
// ... username, password, dbname etc.
];
Click to expand...
Click to expand...
We only expose...
Click to expand...
Read more

Continue reading...
 
BlackSpigot General Chat
Rules Help Users
    H @ HelpAccount: The problem now is that I have two-factor authentication enabled but the email doesn't arrive anyway
    Top