Merge pull request #777 from wingerx/master

fix issue #771 #776 #756
This commit is contained in:
agapple
2018-07-26 10:07:36 +08:00
committed by GitHub
2 changed files with 7 additions and 2 deletions

View File

@@ -54,7 +54,7 @@ public class BinlogDumpCommandPacket extends CommandPacket {
// 1. write 4 bytes bin-log position to start at // 1. write 4 bytes bin-log position to start at
ByteHelper.writeUnsignedIntLittleEndian(binlogPosition, out); ByteHelper.writeUnsignedIntLittleEndian(binlogPosition, out);
// 2. write 2 bytes bin-log flags // 2. write 2 bytes bin-log flags
int binlog_flags = BINLOG_DUMP_NON_BLOCK; int binlog_flags = 0;
binlog_flags |= BINLOG_SEND_ANNOTATE_ROWS_EVENT; binlog_flags |= BINLOG_SEND_ANNOTATE_ROWS_EVENT;
out.write(binlog_flags); out.write(binlog_flags);
out.write(0x00); out.write(0x00);

View File

@@ -303,7 +303,12 @@ public abstract class AbstractEventParser<EVENT> extends AbstractCanalLifeCycle
transactionBuffer.reset();// 重置一下缓冲队列,重新记录数据 transactionBuffer.reset();// 重置一下缓冲队列,重新记录数据
binlogParser.reset();// 重新置位 binlogParser.reset();// 重新置位
if (multiStageCoprocessor != null) { if (multiStageCoprocessor != null) {
multiStageCoprocessor.reset(); // 处理 RejectedExecutionException
try {
multiStageCoprocessor.reset();
} catch (Throwable t) {
logger.debug("multi processor rejected:", t);
}
} }
if (running) { if (running) {