-
Notifications
You must be signed in to change notification settings - Fork 78
chore: drop migrations older than v1.0.0 #2044
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
base: main
Are you sure you want to change the base?
Conversation
6bbb779 to
fdab8fa
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR drops all migrations older than v1.0.0 and removes deprecated resource types that were only maintained for those migrations. The goal is to simplify the codebase by requiring users to upgrade to v1.0.0 first before upgrading to newer versions, rather than supporting direct upgrades from very old versions.
Key changes:
- Replaced 46 old migration callbacks with a
gapErrorfunction that returns an error message - Removed deprecated resource types:
ClusterMachineTemplate,ExtensionsConfigurationStatus, andDeprecatedLinkCounter - Deleted migration helper functions and tests for old migrations
Reviewed changes
Copilot reviewed 24 out of 25 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
internal/backend/runtime/omni/migration/migrations.go |
Replaced old migration callbacks with gapError function |
internal/backend/runtime/omni/migration/manager.go |
Updated migration list to use gapError for pre-v1.0.0 migrations |
internal/backend/runtime/omni/migration/migration_test.go |
Removed tests for old migrations, kept tests for v1.0+ migrations |
internal/backend/runtime/omni/migration/helpers.go |
Deleted file containing helper functions only used by old migrations |
internal/backend/runtime/omni/migration/compat.go |
Deleted file with deprecated constants and helper functions |
internal/backend/runtime/omni/migration/deprecated_resources_test.go |
Deleted test file for deprecated resources |
internal/backend/runtime/omni/state_access.go |
Removed references to deprecated resource types |
internal/integration/auth_test.go |
Removed test cases for deprecated resources |
client/pkg/omni/resources/omni/cluster_machine_template.go |
Deleted deprecated ClusterMachineTemplate resource definition |
client/pkg/omni/resources/omni/extensions_configuration_status.go |
Deleted deprecated ExtensionsConfigurationStatus resource definition |
client/pkg/omni/resources/siderolink/linkcounter.go |
Deleted deprecated DeprecatedLinkCounter resource definition |
client/api/omni/specs/omni.proto |
Reserved field 1 in ClusterSpec, removed deprecated message types |
frontend/src/api/resources.ts |
Removed deprecated resource type constants |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
fdab8fa to
9124766
Compare
Drop old migrations and deprecated types which were kept only for the migrations. Signed-off-by: Utku Ozdemir <utku.ozdemir@siderolabs.com>
9124766 to
dc2b1c9
Compare
smira
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does it fail if we try to start from pre-1.0.0 version?
Drop old migrations and deprecated types which were kept only for the migrations.