Thu Mar 10 20:32:42 PST 2005
- Previous message: [Slony1-general] RE: slow replication since upgrade to 1.0.5
- Next message: [Slony1-general] disabling triggers
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
This is not strictly a slony question, but it has to do with some slony
procedure code I would like to emulate... I have a data broadcasting
functionality that is layered on top of a slony installation that I use
to get data replicated out to nodes from a central location without
those nodes having to be part of this slony cluster (all nodes are
actually pairs, Active/Standby, and we are using our trusty slony to
maintain data redundancy between them).
When a node subscribes I want to do an initial delete/copy of a set of
tables the way slony does, but I need to get around FK constraints. My
understanding of the altertableforreplication procedure is:
- for each table that needs to be altered and has
triggers/constraints
-update the pg_triggers record for each trigger to point to
the table's primary key object (maintained
in the sl_table table)
- update the record for the current table in pg_class to
decrement the reltriggers column
And then the restore reverses this process.
The procedure also disables rules - are both of these steps necessary to
"disable" constraints, or is it sufficient to just point the triggers
away?
I'm not sure I can implement this the same way, because I don't
necessarily have a primary key to substitute with on all of the target
tables, but I can build in some other kind of table to my schema to help
track these relations.
But first, am I understanding correctly the way altertableforreplication
works?!
Thanks.
- DAP
------------------------------------------------------------------------
----------
David Parker Tazz Networks (401) 709-5130
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gborg.postgresql.org/pipermail/slony1-general/attachments/20050310/e77520b5/attachment-0001.html
- Previous message: [Slony1-general] RE: slow replication since upgrade to 1.0.5
- Next message: [Slony1-general] disabling triggers
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Slony1-general mailing list