mirror of
https://github.com/alibaba/canal.git
synced 2026-11-04 00:30:15 +08:00
= performance improve
- using bulk operation instead of iteration if possible - terminate loop after condition is met
This commit is contained in:
@@ -20,6 +20,7 @@ public class HeartBeatEntryEventHandler extends AbstractCanalEventDownStreamHand
|
||||
for (Event event : events) {
|
||||
if (event.getEntryType() == EntryType.HEARTBEAT) {
|
||||
existHeartBeat = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user