Releases for sf 1.0
| Version |
License |
API |
Released |
|
1.0.2stable
|
MIT license |
1.0.1stable
|
21/11/2008 |
|
1.0.1stable
|
MIT license |
1.0.0stable
|
20/11/2008 |
|
1.0.0stable
|
MIT license |
1.0.0stable
|
20/11/2008 |
Changelog for release 1.0.2 - 21/11/2008
Other releases
Release 1.0.2 - 21/11/2008
Release 1.0.1 - 20/11/2008
Release 1.0.0 - 20/11/2008
tncPropel12LoadbalancerPlugin plugin
Overview
This plugin extends the SfPeerBuilder to add the Load Balance feature to Propel 1.2.
Installation
cd my_project
php symfony plugin-install http://plugins.symfony-project.com/tncPropel12LoadbalancerPlugin
php symfony cc
Requirements
Server Side:
Usage
Edit the databases.yml file of your project and change the following entry:
my_db_master:
class: sfPropelDatabase
param:
phptype: mysql
host: 192.168.0.1
database: db_name
username: username
password: password
encoding: utf8
connectionReadOnly: my_db_slave_1, my_db_slave_2
my_db_slave_1:
class: sfPropelDatabase
param:
phptype: mysql
host: 192.168.0.2
database: db_name
username: username
password: password
encoding: utf8
my_db_slave_2:
class: sfPropelDatabase
param:
phptype: mysql
host: 192.168.0.3
database: db_name
username: username
password: password
encoding: utf8
Edit the propel.ini and change the following entry:
propel.builder.peer.class = plugins.tncPropel12LoadbalancerPlugin.lib.tncPeerBuilder
Rebuild the model
Clear the cache
As shown here, on the custom connectionReadOnly attribute we enter our slaves connection names.
License
For the full copyright and license information, please view the LICENSE file that was distributed with this source code.