Skip to content

Commit 0bb4977

Browse files
authored
snapshot(ticdc): fix ddl puller and ddl manager stuck caused by two dead lock (#11886)
close #11884
1 parent 6a53270 commit 0bb4977

File tree

2 files changed

+1
-5
lines changed

2 files changed

+1
-5
lines changed

cdc/entry/schema/snapshot.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -570,9 +570,6 @@ func (s *Snapshot) SchemaCount() (count int) {
570570

571571
// DumpToString dumps the snapshot to a string.
572572
func (s *Snapshot) DumpToString() string {
573-
s.rwlock.RLock()
574-
defer s.rwlock.RUnlock()
575-
576573
schemas := make([]string, 0, s.inner.schemas.Len())
577574
s.IterSchemas(func(dbInfo *timodel.DBInfo) {
578575
schemas = append(schemas, fmt.Sprintf("%v", dbInfo))

cdc/entry/schema_storage.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -273,8 +273,7 @@ func (s *schemaStorage) AllPhysicalTables(ctx context.Context, ts model.Ts) ([]m
273273
log.Debug("get new schema snapshot",
274274
zap.Uint64("ts", ts),
275275
zap.Uint64("snapTs", snap.CurrentTs()),
276-
zap.Any("tables", res),
277-
zap.String("snapshot", snap.DumpToString()))
276+
zap.Any("tables", res))
278277

279278
return res, nil
280279
}

0 commit comments

Comments
 (0)