From a6cc062c14f39cb3201bc9dde68f8688afe2247d Mon Sep 17 00:00:00 2001 From: Seth Hoenig Date: Wed, 23 Feb 2022 14:29:37 -0600 Subject: [PATCH] client: resolve rebase conflict --- client/state/upgrade.go | 3 ++- client/state/upgrade_int_test.go | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/client/state/upgrade.go b/client/state/upgrade.go index 38c3693cdc0..31f8c3bef6d 100644 --- a/client/state/upgrade.go +++ b/client/state/upgrade.go @@ -11,8 +11,9 @@ import ( "github.com/hashicorp/nomad/client/dynamicplugins" "github.com/hashicorp/nomad/helper/boltdd" "github.com/hashicorp/nomad/nomad/structs" + "go.etcd.io/bbolt" ) - + // NeedsUpgrade returns true if the BoltDB needs upgrading or false if it is // already up to date. func NeedsUpgrade(bdb *bbolt.DB) (upgradeTo09, upgradeTo13 bool, err error) { diff --git a/client/state/upgrade_int_test.go b/client/state/upgrade_int_test.go index 540b3f33b7b..96df3fbadce 100644 --- a/client/state/upgrade_int_test.go +++ b/client/state/upgrade_int_test.go @@ -11,7 +11,6 @@ import ( "strings" "testing" - "github.com/boltdb/bolt" "github.com/hashicorp/nomad/client/allocrunner" "github.com/hashicorp/nomad/client/allocwatcher" clientconfig "github.com/hashicorp/nomad/client/config" @@ -27,6 +26,7 @@ import ( pstructs "github.com/hashicorp/nomad/plugins/shared/structs" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" + "go.etcd.io/bbolt" ) // TestBoltStateDB_Upgrade_Ok asserts upgading an old state db does not error @@ -140,7 +140,7 @@ func TestBoltStateDB_UpgradeOld_Ok(t *testing.T) { defer db.Close() // Simply opening old files should *not* alter them - db.DB().BoltDB().View(func(tx *bolt.Tx) error { + db.DB().BoltDB().View(func(tx *bbolt.Tx) error { b := tx.Bucket([]byte("meta")) if b == nil { return fmt.Errorf("meta bucket should exist")