您好,欢迎来到三六零分类信息网!老站,搜索引擎当天收录,欢迎发信息

SymmetricDS同步一个表的步骤

2026/3/11 5:09:10发布11次查看
1. 创建一个channel insert into sym_channel(channel_id, processing_order, max_batch_size, enabled, description)values(test, 1, 100000, 1, channel test for table test) 一个channel是一个或多个希望在一个事务中同步的表的集合 2. 为要同步的表创建
1. 创建一个channelinsert into sym_channel(channel_id, processing_order, max_batch_size, enabled, description)values('test', 1, 100000, 1, 'channel test for table test')
一个channel是一个或多个希望在一个事务中同步的表的集合
2. 为要同步的表创建trigger
insert into sym_trigger(trigger_id,source_table_name,channel_id,last_update_time,create_time)values('test','test','test',current_timestamp,current_timestamp);
每一个表创建一个同步trigger(还有dead 类型的trigger),并将这个表放到一个channel中。
3.创建router
insert into sym_router(router_id,source_node_group_id,target_node_group_id,router_type,create_time,last_update_time)values('test_2_test', 'corp', 'store', 'default',current_timestamp, current_timestamp);
创建一个router,router具有方向的概念。并且可以对数据进行过滤。
4.创建trigger-router link
insert into sym_trigger_router(trigger_id,router_id,initial_load_order,last_update_time,create_time)values('test','test_2_test', 100, current_timestamp, current_timestamp);
需要将trigger和router联系起来,也就是将trigger获取的数据传递到router中,然后router再往其他节点发送。trigger和router是多对多的关系。所以需要一个join表的存在。这就是那个join表。
该用户其它信息

VIP推荐

免费发布信息,免费发布B2B信息网站平台 - 三六零分类信息网 沪ICP备09012988号-2
企业名录 Product