Skip to content

Commit 6b51b98

Browse files
authored
Merge pull request #623 from Zaynullin/fake-rotate-event-check-v0-45-1
Fixing an issue of initializing table map when fake rotate event catching for Mysql versions 5.5, 5.6, 5.7
2 parents 022cd15 + 25c9766 commit 6b51b98

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pymysqlreplication/binlogstream.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -554,7 +554,8 @@ def fetchone(self):
554554
# invalidates all our cached table id to schema mappings. This means we have to load them all
555555
# again for each logfile which is potentially wasted effort but we can't really do much better
556556
# without being broken in restart case
557-
self.table_map = {}
557+
if binlog_event.timestamp != 0:
558+
self.table_map = {}
558559
elif binlog_event.log_pos:
559560
self.log_pos = binlog_event.log_pos
560561

0 commit comments

Comments
 (0)