mysql - Should my database driver classes support replication (PHP)? -


I am currently writing driver (classes) for a PHP application and database engine. I was thinking that I have to write a replica support (master-slave)? I'm a little new on this, so, if I want to support load balancing / replication, then what kind of things should my project or classes worry about? Oh, and it's about MySQL.

The way we use our Master-slave DB, it's all "active" Use "for mastering, and for all reporting, slaves (where the data is still" catch up ", there is no problem) depending on your needs, you may be the master-sub-data manipulation, and slave All-over data can be read. This particularly helps when you block inclusion or update. (Note: With this, click on "Block Delay", where possible, MySQL syntax, which helps to avoid blocking.)

As far as PHP support for this, All of you really need to have clean handling (two) database connections for many, and use the master (read / write) or slave (read-only) DB connections as desired.


Comments

Popular posts from this blog

c++ - Linux and clipboard -

What is expire header and how to achive them in ASP.NET and PHP? -

sql server - How can I determine which of my SQL 2005 statistics are unused? -