Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

canal server running节点判断是否为本机操作优化 #27

Closed
agapple opened this issue Apr 3, 2013 · 0 comments
Closed

canal server running节点判断是否为本机操作优化 #27

agapple opened this issue Apr 3, 2013 · 0 comments
Assignees
Milestone

Comments

@agapple
Copy link
Member

agapple commented Apr 3, 2013

canal server在zookeeper的节点:

[zk: localhost:2181(CONNECTED) 15] get /otter/canal/destinations/example/running  
{"active":true,"address":"10.20.144.51:11111","cid":1}

目前一台机器,判断当前是否为工作节点,是通过cid是否和本机的id相同来判断,但目前cid这信息在启动canal server没有严格校验是否有重复,导致两台机器都认为是自己本机,对于后续的命令控制操作有风险

解决:将判断是否本机的操作,修改为基于address是否相同来判断,ip+port可以唯一定义一个jvm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant