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

MoveTables doesn't migrate sequence in VSchema definition #9002

Closed
derekperkins opened this issue Oct 15, 2021 · 2 comments
Closed

MoveTables doesn't migrate sequence in VSchema definition #9002

derekperkins opened this issue Oct 15, 2021 · 2 comments

Comments

@derekperkins
Copy link
Member

Overview of the Issue

When migrating from a sharded keyspace to an unsharded keyspace, my expectation was that the sequence would continue to be applied afterwards, but it wasn't in the vschema definition. I quickly re-added it, so I didn't do any testing to see how it actually behaved.

Before MoveTables (sharded keyspace)

    "semetrics_grepwords_pipeline": {
      "autoIncrement": {
        "column": "pipeline_id",
        "sequence": "semetrics_grepwords_pipeline_seq"
      }
    },

After MoveTables (unsharded keyspace)

    "semetrics_grepwords_pipeline": {}

Operating system and Environment details

vttablet: 11.0.1
vtctld: 11.0.1
vtgate: 10.0.0

@DeathBorn
Copy link
Contributor

I think for Movetables, one needs to provide vindexes or/and sequence definitions for target. In v8, when moving unsharded to sharded, I had to provide both.

Another note, when Movetables and switchwrites is performed on sequence table, tables which use that sequence table do not respect routing rules at all. Maybe sequence tables should not be migrated in that way.

@rohit-nayak-ps
Copy link
Contributor

Closed via #9288

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants