Pressflow has become very popular among midsize and large sites. It uses a dedicated variable, $db_slave_url, for collecting the database connection strings of slave dbs. Our reports should be able to run against these slaves. customreports already can use non default databases but not those specificied by pressflow.

i will soon be adding this feature. feedback welcome. see https://wiki.fourkitchens.com/display/PF/Using+database+replication+with... for more detail on pressflow's implementation.

Comments

Race.it’s picture

Status: Active » Needs review
StatusFileSize
new891 bytes

I have created a patch for this, let me know if its sufficient?

moshe weitzman’s picture

Awesome. Thanks.

Do folks have a need to run some reports on the master and some on the slave? Seems like a pretty exotic need so this patch should suffice. We should add the URL I pasted to the code comment so folks learn about pressflow's slave support.

moshe weitzman’s picture

I think this patch is incompatible with the 'use foo' trick. See code just above this one. We should put this code in an else against that code or otherwise make them work together better.

Race.it’s picture

StatusFileSize
new1.42 KB

My bad, I had used the head for the patch, I have now rerolled the patch against the 6.x-1.x-dev branch.

moshe weitzman’s picture

thx. just a typo now: instalation

Race.it’s picture

StatusFileSize
new1.42 KB

New patch with installation spelt right :)

Race.it’s picture

StatusFileSize
new1.72 KB

Change the patch files comments around, so the comments are more structured.

moshe weitzman’s picture

Status: Needs review » Fixed

Committed to 6.x. Thanks.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.