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

migrations: persist the version setting for 1.1-initialized clusters #17389

Closed
tbg opened this issue Aug 2, 2017 · 0 comments
Closed

migrations: persist the version setting for 1.1-initialized clusters #17389

tbg opened this issue Aug 2, 2017 · 0 comments
Assignees
Milestone

Comments

@tbg
Copy link
Member

tbg commented Aug 2, 2017

As a follow-up to #17216, we want to make sure that there is always a persisted version cluster setting for folks running 1.1. In particular, this means that a new cluster initialized using v1.1 should have a persisted version setting.

@dt pointed out in #17216 that there is a precedent:

#17216 (comment)

For the diagnostic reporting setting, semantically we wanted a default of true, but since settings need to be allowed to return defaults until they are read and didn't want to risk ignoring an explicit false and betraying user trust, we went with a default of false with a startup migration writing an explicit true (optInToDiagnosticsStatReporting in migrations.go). This feels pretty similar.

@tbg tbg added this to the 1.1 milestone Aug 2, 2017
tbg added a commit to tbg/cockroach that referenced this issue Aug 16, 2017
This uses the previously added bootstrap version which is populated when a
cluster running >1.0 is bootstrapped to populate the settings table. At the
same time, prevent `SET CLUSTER SETTING version = 'x'` from working until
that migration has run.

This solves one remaining headache for [version migrations][1] by giving it
authoritative information on the currently running cluster version during
upgrades.

Fixes cockroachdb#17389.

[1]: cockroachdb#16977
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

No branches or pull requests

2 participants