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

Reverse workflow: update cells/tablet_types #6556

Merged
merged 1 commit into from
Aug 17, 2020

Conversation

rohit-nayak-ps
Copy link
Contributor

@rohit-nayak-ps rohit-nayak-ps commented Aug 12, 2020

VReplication creates a reverse workflow on SwitchWrites so that it is possible to revert a MoveTables or Reshard. However the cell/tablet_types columns in _vt.vreplication are currently not updated with the options provided on the command line.

This PR fixes that:

  • we use the same tablet_types in the reverse workflow
  • we use the same cells list, except: if the source and target keyspaces are different and the forward workflow included the
    target's cell (but not the source's) we use the source cell instead.

We chose this approach instead of adding more cli options to specify tablet_types/cells for the reverse workflow as a simpler initial implementation. We can add the extra options if we find valid use-cases for it.

Signed-off-by: Rohit Nayak [email protected]

@rohit-nayak-ps rohit-nayak-ps marked this pull request as ready for review August 13, 2020 20:29
@rohit-nayak-ps rohit-nayak-ps requested a review from sougou as a code owner August 13, 2020 20:29
@rohit-nayak-ps rohit-nayak-ps requested a review from deepthi August 13, 2020 20:29
Copy link
Member

@deepthi deepthi left a comment

Choose a reason for hiding this comment

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

The implementation looks fine. The only concern is whether it is valid to assume that the cells / tablet_types provided for the forward workflow are the same ones we should use for reverse.
Probably fine for the first implementation.
Can you please update the PR with a description of why this PR and a brief summary of implementation?

@deepthi deepthi merged commit 02fa884 into vitessio:master Aug 17, 2020
@askdba askdba added this to the v8.0 milestone Oct 5, 2020
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.

3 participants