mysql debezium - snapshot - global read lock

27 views
Skip to first unread message

추어른이 되지 못한 아이

unread,
Mar 21, 2023, 8:03:24 PM3/21/23
to debezium
Hi, I have a question during snapshot for mysql debezium

As doc mentioned,
Grabs a global read lock that blocks writes by other database clients. >

1.
It means debezium lock all tables for read lock so that DML also can't be operated?

2.
if i want to snapshot only one table using table.include.list, then, debezium still get global read lock so i can't use DML or DDL?

Chris Cranford

unread,
Mar 22, 2023, 7:49:08 AM3/22/23
to debe...@googlegroups.com
Hi,

Yes, this lock prevents DML and DDL operations from occurring while it is active.  This lock is only taken once on an initial new connector start-up and is kept for a brief moment in time where the connector is reading the table metadata for each table.  It's necessarily in order to take a consistent schema snapshot.  Once the schema has been read, the lock is released and the system can safely begin to accept DML and DDL changes while the connector snapshots the data from the captured tables. 

Hope that helps.
Chris
--
You received this message because you are subscribed to the Google Groups "debezium" group.
To unsubscribe from this group and stop receiving emails from it, send an email to debezium+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/debezium/c1438ed1-fed7-4c3f-b165-7ed83a0df94bn%40googlegroups.com.

Reply all
Reply to author
Forward
0 new messages