From 258d3e7a48f37af2681f2b22371305d31acc045a Mon Sep 17 00:00:00 2001 From: Brian Meek Date: Wed, 3 Aug 2022 10:42:32 -0700 Subject: [PATCH] Remove no longer needed mutex for guarding goose Signed-off-by: Brian Meek --- internal/sqlutil/migrate.go | 5 ----- 1 file changed, 5 deletions(-) diff --git a/internal/sqlutil/migrate.go b/internal/sqlutil/migrate.go index 56d906f29..18020a902 100644 --- a/internal/sqlutil/migrate.go +++ b/internal/sqlutil/migrate.go @@ -48,9 +48,6 @@ type Migration struct { Down func(ctx context.Context, txn *sql.Tx) error } -// Gaurs the internal state of Goose from being modified by concurrent tests or goroutines -var gooseMutex sync.Mutex - // Migrator type Migrator struct { db *sql.DB @@ -84,8 +81,6 @@ func (m *Migrator) AddMigrations(migrations ...Migration) { // Up executes all migrations in order they were added. func (m *Migrator) Up(ctx context.Context) error { - gooseMutex.Lock() - defer gooseMutex.Unlock() var ( err error dendriteVersion = internal.VersionString()