Jan Wieck JanWieck
Thu Mar 16 13:50:23 PST 2006
On 3/16/2006 12:06 AM, Andrew Ng wrote:

> Hi All,
> 
> below is my assumption regarding failover, so please correct me if I'm
> wrong -
> 
> -------------------------------------------------------------------------------
> a table T is created with primary key K (sequence), Slony is configured
> to replicate both table T and primary key K. When a failover is made,
> there could be a short instance where new row(s) are inserted  and
> replicated to the slave, but the sequence's last value is still not
> updated at the slave. As such, subsequent inserts would fail with
> duplicate key error until the slave's value is adjusted, manually or
> otherwise.

This can't happen. Sequences are replicated in a fashion that allows 
them to be more advanced than the data that is actually replicated. In 
case of a failover you would therefore see a gap in the keys, which is 
likely to be equal to the missing transactions that got lost in the 
failover.


Jan

-- 
#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me.                                  #
#================================================== JanWieck at Yahoo.com #



More information about the Slony1-general mailing list