always check whether ringbuffer has an exception in event processor (#2053)

This commit is contained in:
soocold
2019-08-21 12:46:17 +08:00
committed by agapple
parent fdd0763567
commit 066743cfd6

View File

@@ -190,17 +190,17 @@ public class MysqlMultiStageCoprocessor extends AbstractCanalLifeCycle implement
return false;
}
/**
* 由于改为processor仅终止自身stage而不是stop,那么需要由incident标识coprocessor是否正常工作。
* 让dump线程能够及时感知
*/
if (exception != null) {
throw exception;
}
boolean interupted = false;
long blockingStart = 0L;
int fullTimes = 0;
do {
/**
* 由于改为processor仅终止自身stage而不是stop,那么需要由incident标识coprocessor是否正常工作。
* 让dump线程能够及时感知
*/
if (exception != null) {
throw exception;
}
try {
long next = disruptorMsgBuffer.tryNext();
MessageEvent data = disruptorMsgBuffer.get(next);