Skip to content

Commit

Permalink
Improve logging perf (#1219)
Browse files Browse the repository at this point in the history
* Remove association preloads from run verification func

* Add new mlflow alembic version
  • Loading branch information
suprjinx authored May 21, 2024
1 parent 1b18330 commit 753a7e7
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 8 deletions.
6 changes: 0 additions & 6 deletions pkg/api/mlflow/dao/repositories/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,12 +86,6 @@ func (r RunRepository) GetByNamespaceIDRunIDAndLifecycleStage(
run := models.Run{ID: runID}
if err := r.GetDB().WithContext(
ctx,
).Preload(
"LatestMetrics",
).Preload(
"Params",
).Preload(
"Tags",
).Joins(
"INNER JOIN experiments ON experiments.experiment_id = runs.experiment_id AND experiments.namespace_id = ?",
namespaceID,
Expand Down
3 changes: 2 additions & 1 deletion pkg/database/migrate.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ var supportedAlembicVersions = []string{
"7f2a7d5fae7d",
"2d6e25af4d3e",
"acf3f17fdcc7",
"867495a8f9d4",
}

// CheckAndMigrateDB makes database migration.
Expand Down Expand Up @@ -121,7 +122,7 @@ func CheckAndMigrateDB(migrate bool, db *gorm.DB) error {
}
fallthrough

case "97727af70f4d", "3500859a5d39", "7f2a7d5fae7d", "2d6e25af4d3e", "acf3f17fdcc7":
case "97727af70f4d", "3500859a5d39", "7f2a7d5fae7d", "2d6e25af4d3e", "acf3f17fdcc7", "867495a8f9d4":
// run the FML migrations generated by `make migrations-rebuild`
if err := generatedMigrations(db, schemaVersion.Version); err != nil {
return fmt.Errorf("error running generated migrations: %w", err)
Expand Down
2 changes: 1 addition & 1 deletion tests/integration/golang/compatibility/mlflow_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ func (s *MLflowTestSuite) SetupSuite() {
S3EndpointURI: helpers.GetS3EndpointUri(),
GSEndpointURI: helpers.GetGSEndpointUri(),
})
s.Nil(err)
s.Require().Nil(err)
s.server = srv

s.aimClient = func() *helpers.HttpClient {
Expand Down

0 comments on commit 753a7e7

Please sign in to comment.