Christopher Browne cbbrowne at ca.afilias.info
Mon Sep 20 08:04:11 PDT 2010
lai at clustersolutions.net writes:
> Reading throught the doc for Slony it seems that it is okay to add an
> unique index to a replicated table on the master node using psql. We use
> our slave for read-only. I would appreciate any help on this issue before
> carrying out the task. Oh, can I also get a confirmation that it is okay
> to leave out the index on the same table of the slave node?
>
> Thank you so much for your help!

Sure, that's perfectly reasonable to do.

Putting a unique index onto a replicated on a subscriber is an entirely
riskier endeavour, as that puts a constraint onto the subscriber which
the provider was not required to satisfy.

*That* would give the risk that an application puts data onto the
"master" node that won't be accepted by the subscriber, thereby causing
replication to fail.

The failure mode isn't completely heinous - replication  stops, and the
subscriber's replication logs will complain about the violation of the
unique constraint.  The sad thing that happens next is that the
subscriber will try this over and over, failing every time :-(.

But that's not the case you're talking about - you're talking about
putting an extra constaint on the "master."  No particular problem with
that.
-- 
output = reverse("ofni.sailifa.ac" "@" "enworbbc")
Christopher Browne
"Bother,"  said Pooh,  "Eeyore, ready  two photon  torpedoes  and lock
phasers on the Heffalump, Piglet, meet me in transporter room three"


More information about the Slony1-general mailing list