From 0b4f03a32916cd23177ae017c5969bf077658be5 Mon Sep 17 00:00:00 2001 From: Chunzhu Li Date: Thu, 24 Dec 2020 01:21:39 -0600 Subject: [PATCH] fix metaConn hold lock (#221) --- v4/export/dump.go | 1 + 1 file changed, 1 insertion(+) diff --git a/v4/export/dump.go b/v4/export/dump.go index f953ad96..c746ea9b 100755 --- a/v4/export/dump.go +++ b/v4/export/dump.go @@ -116,6 +116,7 @@ func (d *Dumper) Dump() (dumpErr error) { if err != nil { return err } + defer metaConn.Close() m.recordStartTime(time.Now()) // for consistency lock, we can write snapshot info after all tables are locked. // the binlog pos may changed because there is still possible write between we lock tables and write master status.