-
Notifications
You must be signed in to change notification settings - Fork 4.1k
migration/startupmigrations: remove all startupmigrations #73813
Description
Is your feature request related to a problem? Please describe.
Before long-running migrations, there were migrations which ran at startup. We haven't really leveraged these in a while (none since 20.2). There are, however, "permanent" migrations which set up some initial cluster state. We should get rid of that concept and all the complexity that comes with it.
Describe the solution you'd like
Move any permanent migrations into bootstrap. Some of the remaining seem to not really be permanent.
Remaining permanent migrations:
optIntoDiagnosticsReportingpopulateVersionSettingaddRootUseraddAdminRoleaddRootToAdminRoleinitializeClusterSecretdisallowPublicUserOrRolecreateDefaultDatabasesretireOldTsPurgeIntervalSettingsupdateSystemLocationDataextendCreateRoleWithCreateLogin
Describe alternatives you've considered
We could not do this. An advantage to startup migrations is that they get to leverage the running system and, in doing so, may gain benefit from more code reuse.
Additional context
The pressing migration which motivated this was createDefaultDatabases.
Jira issue: CRDB-11759
Epic CRDB-18596