Closed markharding closed 9 years ago
@markharding Good point. Will add a method to stay inline with the yaml definition.
@markharding A PR is waiting for merge after the Travis build.
config :
$client = ClientBuilder::create()
->addConnection('server1', 'http', '193.147.213.3', 7474)
->addConnection('server2', 'http', '193.147.213.4', 7474)
->addConnection('server3', 'http', '193.147.213.7', 7474)
->setMasterConnection('server1') // Define the Master Connection by providing the connection alias
->setSlaveConnection('server2') // Idem for slave connections
->setSlaveConnection('server3')
->enableHAMode()
->build();
Please note that this will be valid only for Enterprise
mode as the community support will disappear due to NeoTechnology license and rules.
Currently you have to use the YAML config if you want to set ha_mode parameter. A function such as 'setHAMode()' in the connection builder would be helpful.
Currently I'm getting errors thrown because I'm not using the YAML config.
neoxygen/neoclient/src/DependencyInjection/NeoClientExtension.php:64