mysql-binlog-connector-java
mysql-binlog-connector-java copied to clipboard
How to get only the binlog that listens to the specified db database
How to get only the binlog that listens to the specified db database? Now there are many databases under an instance. By processing event filtering, it is found that the delay is very high. Is there a good way to filter out the binlog in the required db by specifying the database when initiating the dump request?
我现在的项目也是遇到类似的情况,一个mysql实例有两个schema,prod和dev,同时启动两个监听客户端,只有一个延迟很低,另一个延迟大概有20s左右,我的方案是重新在另一台服务器上搭建一个mysql,把他们分离开,这样就能保证两边延迟都很低。否则你只能把数据库改成多实例的,并且一个实例对应一个binlog文件,这样应该也能保证低延迟。