I've been using slony in a master to slave1 to slave2 setup.  That is, slave1 
gets its updates from the master and slave2 gets its updates from slave1.  The 
WAIT FOR syntax I've been using looks like this:

SUBSCRIBE SET (id=9998, provider=1, receiver=2, forward=yes);
WAIT FOR EVENT (origin=2, confirmed=1, wait on=2);
SYNC(id = 1);
WAIT FOR EVENT (origin=1, confirmed=2, wait on=1);

SUBSCRIBE SET (id=9998, provider=2, receiver=3, forward=no);
WAIT FOR EVENT (origin=3, confirmed=2, wait on=3);
SYNC(id = 2);
WAIT FOR EVENT (origin=2, confirmed=3, wait on=2);

MERGE SET ( id = 1, add id = 9998, origin = 1 );

I have a new setup that will be two slaves with both of them getting updates 
from the master and I'm wondering what the correct syntax for that would be?

Maybe something like this:

SUBSCRIBE SET (id=9998, provider=1, receiver=2, forward=no);
WAIT FOR EVENT (origin=2, confirmed=1, wait on=2);
SYNC(id = 1);
WAIT FOR EVENT (origin=1, confirmed=2, wait on=1);

SUBSCRIBE SET (id=9998, provider=1, receiver=3, forward=no);
WAIT FOR EVENT (origin=3, confirmed=1, wait on=3);
SYNC(id = 1);
WAIT FOR EVENT (origin=1, confirmed=3, wait on=1);

MERGE SET ( id = 1, add id = 9998, origin = 1 );

?

-- 
Jeff Frost, Owner       <[EMAIL PROTECTED]>
Frost Consulting, LLC   http://www.frostconsultingllc.com/
Phone: 650-780-7908     FAX: 650-649-1954
_______________________________________________
Slony1-general mailing list
[email protected]
http://gborg.postgresql.org/mailman/listinfo/slony1-general

Reply via email to