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

Fix wrong path in metric migration #969

Merged
merged 2 commits into from
Feb 19, 2024
Merged

Conversation

peterjan
Copy link
Member

Recently had to add a metric migration and found that we don't properly build the path in performMigration, it always uses main:

// build path
var path string
if isSQLite(db) {
    path = fmt.Sprintf("migrations/sqlite/main/migration_" + name + ".sql")
} else {
    path = fmt.Sprintf("migrations/mysql/main/migration_" + name + ".sql")
}

Tested it with a dummy metrics/main migration on my MySQL node.

@peterjan peterjan self-assigned this Feb 15, 2024
stores/migrations_utils.go Outdated Show resolved Hide resolved
stores/migrations_utils.go Outdated Show resolved Hide resolved
@ChrisSchinnerl ChrisSchinnerl merged commit 267d5b3 into dev Feb 19, 2024
8 checks passed
@ChrisSchinnerl ChrisSchinnerl deleted the pj/metric-migrations branch February 19, 2024 13:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants