:database => 'abc',
:username => 'xxxxx',
:password => '****',
:host => '192.168.2.27',
:schema_search_path=> 'abcd'
}
config.options[:database_connection_timeout]=200
config.options[:replicator] = :two_way
config.options[:replication_interval] = 10
config.options[:initial_sync]= :True
config.include_tables 'she1',:right_record_handling => :delete, :right_change_handling => :ignore, :replication_conflict_handling => :left_wins , :sync_conflict_handling => :left_wins;
config.include_tables 'he01',:left_record_handling => :delete, :left_change_handling => :ignore, :replication_conflict_handling => :right_wins , :sync_conflict_handling => :right_wins;
config.options[:rep_prefix] = 'u1'
config.options[:auto_key_limit] = 1
config.options[:after_infrastructure_setup] = lambda do |session| [:left, :right].each do |database|
session.send(database).execute("GRANT SELECT, UPDATE, INSERT ON u1_pending_changes TO public ")
session.send(database).execute("GRANT SELECT, UPDATE, INSERT ON u1_running_flags TO public ")
session.send(database).execute("GRANT ALL ON u1_pending_changes_id_seq TO public ")
end
end
end
I am unable to give you any solution for your problem. However, the above is the config i am using to replicate between two systems
On both the systems the Database name, Scheema name,table name etc are same.