Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

修复mysql meta文件记录出错可能存在重启后重复读取数据的问题 #627

Merged
merged 1 commit into from
Jul 23, 2018

Conversation

redHJ
Copy link
Collaborator

@redHJ redHJ commented Jul 23, 2018

meta重复记录问题修复
@wonderflow

@@ -489,17 +507,17 @@ func (dbRecords *SyncDBRecords) restoreRecordsFile(meta *reader.Meta) (lastDB, l
return lastDB, lastTable, true
}

omitDoneDBRecords = true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

默认不是false吗?true的时候你直接return了

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

因为现在出错的时候会continue,不是直接return true了

mrCron.SyncMeta()
mrCron.Close()
//mrCron.SyncMeta()
//mrCron.Close()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里为什么注释了

@wonderflow
Copy link
Contributor

LGTM

@wonderflow wonderflow merged commit 4cdcbdd into qiniu:master Jul 23, 2018
@wonderflow wonderflow changed the title meta fix 修复mysql meta文件记录出错可能存在重启后重复读取数据的问题 Jul 23, 2018
@redHJ redHJ deleted the sqlmetafix branch January 10, 2019 06:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants