SymmetricDS配置Initial Load的步驟,symmetricdsinitial

來源:互聯網
上載者:User

SymmetricDS配置Initial Load的步驟,symmetricdsinitial

Trigger中有一種Dead Trigger,用法較多,可以參考其定義,其中一個就是恢複單向同步的表的初始負載。也就是說要發起一次初始負載,就是要建立一個Dead Trigger。

1.      建立一個channel

insert intosym_channel(channel_id,processing_order, max_batch_size, enabled, description)values('sale_transaction', 1, 100000, 1,'sale_transactional data from register and back office');

2.      建立一個Dead Trigger,將想要初始負載的表加入到channel中,初始負載的方向是單向的

insert intosym_trigger(trigger_id,source_table_name,channel_id,sync_on_insert, sync_on_update, sync_on_delete, last_update_time,create_time)values('sale_transaction_dead','sale_transaction','sale_transaction',0,0,0,current_timestamp,current_timestamp);

3.      建立一個Router

insert intosym_router(router_id,source_node_group_id,target_node_group_id,router_type,create_time,last_update_time)values('store_2_corp', 'store', 'corp','default',current_timestamp, current_timestamp);

4.      建立一個trigger-router組合

insert intosym_trigger_router(trigger_id,router_id,initial_load_order,last_update_time,create_time)values('sale_transaction_dead','store_2_corp', 200,current_timestamp, current_timestamp);

經過上邊的四步之後,在一個節點註冊到另一個節點的之後,下一步就是initial load的過程。要重新load一次,可以在initial load過程中輸出資料的節點上運行下面的命令:

../bin/symadmin --engine corp-000reload-node 001

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.