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

Bug Report: cannot update _vt.schema_migrations table schema if zero values present in requested_timestamp #12261

Closed
shlomi-noach opened this issue Feb 7, 2023 · 0 comments · Fixed by #12262
Assignees
Labels
Component: General Changes throughout the code base Component: Online DDL Online DDL (vitess/native/gh-ost/pt-osc) Component: VReplication Type: Bug

Comments

@shlomi-noach
Copy link
Contributor

Overview of the Issue

Historically, there have been zero values in _vt.schema_migrations.requested_timestamp column; this was due t oa bug, fixed in 3012060#diff-d7427b60825b46773b837642e539fd8f00382fc230b717043f3aa76d3ee7ae14R103

Unfortunately, those values violate the default sql_mode, which includes no_zero_date and no_zero_in_date.

If we make changes to _vt.schema_migrations table, via the schemadiff mechanism, and if zero values are found in requested_timestamp column, then those schema changes will fail, and the tablet will not be able to initialize properly.

Reproduction Steps

deploy recent version, with an old migration that has 0000-00-00 00:00:00 value for requested_timestamp.

Binary Version

-

Operating System and Environment details

-

Log Fragments

No response

@shlomi-noach shlomi-noach added Type: Bug Needs Triage This issue needs to be correctly labelled and triaged labels Feb 7, 2023
@shlomi-noach shlomi-noach self-assigned this Feb 7, 2023
@deepthi deepthi changed the title Bug Report: cannot update _vt,schema_migrations table schema if zero values present in requested_timestamp Bug Report: cannot update _vt.schema_migrations table schema if zero values present in requested_timestamp Feb 9, 2023
@rohit-nayak-ps rohit-nayak-ps added Component: VReplication Component: General Changes throughout the code base Component: Online DDL Online DDL (vitess/native/gh-ost/pt-osc) and removed Needs Triage This issue needs to be correctly labelled and triaged labels Feb 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: General Changes throughout the code base Component: Online DDL Online DDL (vitess/native/gh-ost/pt-osc) Component: VReplication Type: Bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants