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

schemamanager: Change PreflightSchemaChange to accept a list of changes instead of a single change. #1749

Merged
merged 4 commits into from Jun 3, 2016

Conversation

michael-berlin
Copy link
Contributor

@michael-berlin michael-berlin commented Jun 1, 2016

This makes it easier to test multiple changes which depend on each other e.g. a CREATE TABLE after a DROP TABLE if the table already exists.

Fixes issue #1731 (comment).

@alainjobart


This change is Reviewable

…ious SQL statements within the same ApplySchema command are not considered.

For example, ApplySchema could DROP and then CREATE a table. Since the DROP is not considered during preflight, CREATE will fail with the error that the table already exists.
…es instead of a single change.

This makes it easier to test multiple changes which depend on each other e.g. a CREATE TABLE after a DROP TABLE if the table already exists.

Fixes issue vitessio#1731 (comment).
@alainjobart
Copy link
Contributor

alainjobart commented Jun 2, 2016

LGTM

Approved with PullApprove

This simplifies executing the new PreflightSchema and passing on its response.
@michael-berlin
Copy link
Contributor Author

@alainjobart Please have a look at the last commit. I've moved the message into the proto. This made the new PreflightSchema RPC simpler.

@alainjobart
Copy link
Contributor

alainjobart commented Jun 3, 2016

LGTM good idea.

Approved with PullApprove

@michael-berlin michael-berlin merged commit c248d79 into vitessio:master Jun 3, 2016
@michael-berlin michael-berlin deleted the schema_fix branch June 3, 2016 20:20
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.

None yet

3 participants