I'm looking for some advice on best practice for dealing with replicated MySQL databases.

My current client has a large database which is split across a RW master and several RO slaves (I believe that's how MySQL replication always works). They're just toying with replacing a lot of their DB code with DBIx::Class.

I assume that other people have been working with similar architecture and I'd be grateful for any advice you might have. In particular we're thinking about problems like:

* How to decide whether to connect to the master or the slave
* Do we maintain a pool of database handles to both masters and slaves.
* Whether it ever makes sense to upgrade a slave connection to a master connection on the fly * How referential integrity works in a world where a slave can be out of date compared to the master (actually, we know the answer to that one - "it doesn't")

All suggestions, gratefully received.

Cheers,

Dave...

_______________________________________________
List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/
Searchable Archive: http://www.grokbase.com/group/[email protected]

Reply via email to