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

sqlccl: remove external storage dependency on RESTORE cleanup #21559

Merged
merged 1 commit into from Jan 19, 2018
Merged

sqlccl: remove external storage dependency on RESTORE cleanup #21559

merged 1 commit into from Jan 19, 2018

Conversation

maddyblue
Copy link
Contributor

If RESTORE failed and attempted to delete the data it had added,
it would fail to do so if the underlying external data had been
deleted. This would cause the job to forever be in a state where the
job could neither be canceled or failed because those methods would
never succeed, causing the job to loop forever in the registry.

Remove the dependency on the external storage by storing the sql
descriptors in the job details.

Release note (enterprise change): make RESTORE cleanup resilient to
external storage failure or removal

Fixes #20261

If RESTORE failed and attempted to delete the data it had added,
it would fail to do so if the underlying external data had been
deleted. This would cause the job to forever be in a state where the
job could neither be canceled or failed because those methods would
never succeed, causing the job to loop forever in the registry.

Remove the dependency on the external storage by storing the sql
descriptors in the job details.

Release note (enterprise change): make RESTORE cleanup resilient to
external storage failure or removal

Fixes #20261
@maddyblue maddyblue requested review from dt and a team January 18, 2018 21:42
@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Contributor

@benesch benesch left a comment

Choose a reason for hiding this comment

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

LGTM, but I'm starting to get worried about the size of rows in the jobs table. Especially since we never GC them. Haven't done the math, so perhaps I'm totally off base.

@maddyblue
Copy link
Contributor Author

I don't think we need to worry about protobuf version skews here (i.e., running restores on different cluster versions) because the cleanup code was added in the 2.0 branch.

1.1 is still affected by this bug, and there's not really a handy way to repair it.

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