move pluginutils -> helper/pluginutils
I wanted a different color bikeshed, so I get to paint it
This commit is contained in:
parent
80c6eb1bc5
commit
be0bab7c3f
|
@ -30,8 +30,8 @@ import (
|
|||
"github.com/hashicorp/nomad/nomad/structs"
|
||||
bstructs "github.com/hashicorp/nomad/plugins/base/structs"
|
||||
"github.com/hashicorp/nomad/plugins/drivers"
|
||||
"github.com/hashicorp/nomad/pluginutils/hclspecutils"
|
||||
"github.com/hashicorp/nomad/pluginutils/hclutils"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/hclspecutils"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/hclutils"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
|
@ -22,7 +22,7 @@ import (
|
|||
nconfig "github.com/hashicorp/nomad/nomad/structs/config"
|
||||
"github.com/hashicorp/nomad/plugins/device"
|
||||
psstructs "github.com/hashicorp/nomad/plugins/shared/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/catalog"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/catalog"
|
||||
"github.com/hashicorp/nomad/testutil"
|
||||
"github.com/stretchr/testify/assert"
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ import (
|
|||
"github.com/hashicorp/nomad/nomad/structs"
|
||||
"github.com/hashicorp/nomad/nomad/structs/config"
|
||||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/version"
|
||||
)
|
||||
|
||||
|
|
|
@ -12,8 +12,8 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/base"
|
||||
bstructs "github.com/hashicorp/nomad/plugins/base/structs"
|
||||
"github.com/hashicorp/nomad/plugins/device"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/pluginutils/singleton"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/singleton"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
|
@ -16,7 +16,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/plugins/device"
|
||||
pstructs "github.com/hashicorp/nomad/plugins/shared/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
// Manager is the interface used to manage device plugins
|
||||
|
|
|
@ -17,7 +17,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/plugins/device"
|
||||
psstructs "github.com/hashicorp/nomad/plugins/shared/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/testutil"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
|
@ -8,7 +8,7 @@ import (
|
|||
"github.com/hashicorp/nomad/client/config"
|
||||
"github.com/hashicorp/nomad/client/fingerprint"
|
||||
"github.com/hashicorp/nomad/nomad/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
// FingerprintManager runs a client fingerprinters on a continuous basis, and
|
||||
|
|
|
@ -11,8 +11,8 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/base"
|
||||
bstructs "github.com/hashicorp/nomad/plugins/base/structs"
|
||||
"github.com/hashicorp/nomad/plugins/drivers"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/pluginutils/singleton"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/singleton"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
|
@ -13,7 +13,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/plugins/drivers"
|
||||
pstructs "github.com/hashicorp/nomad/plugins/shared/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
// ErrDriverNotFound is returned during Dispense when the requested driver
|
||||
|
|
|
@ -16,7 +16,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/plugins/drivers"
|
||||
dtu "github.com/hashicorp/nomad/plugins/drivers/testutils"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/testutil"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
|
|
@ -10,9 +10,9 @@ import (
|
|||
"github.com/hashicorp/nomad/helper/testlog"
|
||||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/plugins/drivers"
|
||||
"github.com/hashicorp/nomad/pluginutils/catalog"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/pluginutils/singleton"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/catalog"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/singleton"
|
||||
)
|
||||
|
||||
type testManager struct {
|
||||
|
|
|
@ -9,8 +9,8 @@ import (
|
|||
"github.com/hashicorp/nomad/client/fingerprint"
|
||||
"github.com/hashicorp/nomad/command/agent/consul"
|
||||
"github.com/hashicorp/nomad/helper/testlog"
|
||||
"github.com/hashicorp/nomad/pluginutils/catalog"
|
||||
"github.com/hashicorp/nomad/pluginutils/singleton"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/catalog"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/singleton"
|
||||
testing "github.com/mitchellh/go-testing-interface"
|
||||
)
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ import (
|
|||
"github.com/hashicorp/nomad/nomad"
|
||||
"github.com/hashicorp/nomad/nomad/structs"
|
||||
"github.com/hashicorp/nomad/nomad/structs/config"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
"github.com/hashicorp/raft"
|
||||
)
|
||||
|
||||
|
|
|
@ -3,9 +3,9 @@ package agent
|
|||
import (
|
||||
"fmt"
|
||||
|
||||
"github.com/hashicorp/nomad/pluginutils/catalog"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/pluginutils/singleton"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/catalog"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/singleton"
|
||||
)
|
||||
|
||||
// setupPlugins is used to setup the plugin loaders.
|
||||
|
|
|
@ -11,7 +11,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/plugins/drivers"
|
||||
"github.com/hashicorp/nomad/plugins/shared/hclspec"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
|
@ -25,7 +25,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/plugins/drivers"
|
||||
dtestutil "github.com/hashicorp/nomad/plugins/drivers/testutils"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
tu "github.com/hashicorp/nomad/testutil"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
|
|
@ -21,7 +21,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/drivers/utils"
|
||||
"github.com/hashicorp/nomad/plugins/shared/hclspec"
|
||||
pstructs "github.com/hashicorp/nomad/plugins/shared/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
|
@ -20,7 +20,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/drivers/utils"
|
||||
"github.com/hashicorp/nomad/plugins/shared/hclspec"
|
||||
pstructs "github.com/hashicorp/nomad/plugins/shared/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
|
@ -17,7 +17,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/drivers"
|
||||
"github.com/hashicorp/nomad/plugins/shared/hclspec"
|
||||
pstructs "github.com/hashicorp/nomad/plugins/shared/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
|
@ -21,7 +21,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/drivers"
|
||||
"github.com/hashicorp/nomad/plugins/shared/hclspec"
|
||||
pstructs "github.com/hashicorp/nomad/plugins/shared/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
|
@ -19,7 +19,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/drivers"
|
||||
"github.com/hashicorp/nomad/plugins/shared/hclspec"
|
||||
pstructs "github.com/hashicorp/nomad/plugins/shared/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
const (
|
||||
|
|
|
@ -33,7 +33,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/drivers"
|
||||
"github.com/hashicorp/nomad/plugins/shared/hclspec"
|
||||
pstructs "github.com/hashicorp/nomad/plugins/shared/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
rktv1 "github.com/rkt/rkt/api/v1"
|
||||
)
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@ package catalog
|
|||
import (
|
||||
"sync"
|
||||
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
var (
|
|
@ -5,7 +5,7 @@ import (
|
|||
|
||||
"github.com/hashicorp/nomad/helper/testlog"
|
||||
"github.com/hashicorp/nomad/nomad/structs/config"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
// TestPluginLoader returns a plugin loader populated only with internal plugins
|
|
@ -13,8 +13,8 @@ import (
|
|||
hcl2 "github.com/hashicorp/hcl2/hcl"
|
||||
"github.com/hashicorp/nomad/nomad/structs/config"
|
||||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/pluginutils/hclspecutils"
|
||||
"github.com/hashicorp/nomad/pluginutils/hclutils"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/hclspecutils"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/hclutils"
|
||||
"github.com/zclconf/go-cty/cty/msgpack"
|
||||
)
|
||||
|
|
@ -2,7 +2,7 @@ package singleton
|
|||
|
||||
import (
|
||||
"github.com/hashicorp/nomad/helper/uuid"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
// future is a sharable future for retrieving a plugin instance or any error
|
|
@ -7,7 +7,7 @@ import (
|
|||
log "github.com/hashicorp/go-hclog"
|
||||
plugin "github.com/hashicorp/go-plugin"
|
||||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
)
|
||||
|
||||
var (
|
|
@ -10,7 +10,7 @@ import (
|
|||
plugin "github.com/hashicorp/go-plugin"
|
||||
"github.com/hashicorp/nomad/helper/testlog"
|
||||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
|
@ -14,7 +14,7 @@ import (
|
|||
"github.com/hashicorp/nomad/helper/uuid"
|
||||
"github.com/hashicorp/nomad/nomad/structs"
|
||||
"github.com/hashicorp/nomad/nomad/structs/config"
|
||||
"github.com/hashicorp/nomad/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/loader"
|
||||
"github.com/hashicorp/nomad/scheduler"
|
||||
"github.com/hashicorp/raft"
|
||||
"github.com/hashicorp/serf/serf"
|
||||
|
|
|
@ -14,8 +14,8 @@ import (
|
|||
"github.com/hashicorp/nomad/helper/testlog"
|
||||
"github.com/hashicorp/nomad/nomad/mock"
|
||||
"github.com/hashicorp/nomad/nomad/structs"
|
||||
"github.com/hashicorp/nomad/pluginutils/catalog"
|
||||
"github.com/hashicorp/nomad/pluginutils/singleton"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/catalog"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/singleton"
|
||||
)
|
||||
|
||||
var (
|
||||
|
|
|
@ -6,7 +6,7 @@ import (
|
|||
|
||||
"github.com/hashicorp/nomad/plugins/base/proto"
|
||||
"github.com/hashicorp/nomad/plugins/shared/hclspec"
|
||||
"github.com/hashicorp/nomad/pluginutils/grpcutils"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/grpcutils"
|
||||
)
|
||||
|
||||
// BasePluginClient implements the client side of a remote base plugin, using
|
||||
|
|
|
@ -9,7 +9,7 @@ import (
|
|||
"github.com/golang/protobuf/ptypes"
|
||||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/plugins/device/proto"
|
||||
"github.com/hashicorp/nomad/pluginutils/grpcutils"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/grpcutils"
|
||||
)
|
||||
|
||||
// devicePluginClient implements the client side of a remote device plugin, using
|
||||
|
|
|
@ -16,7 +16,7 @@ import (
|
|||
"github.com/hashicorp/nomad/plugins/shared/hclspec"
|
||||
pstructs "github.com/hashicorp/nomad/plugins/shared/structs"
|
||||
sproto "github.com/hashicorp/nomad/plugins/shared/structs/proto"
|
||||
"github.com/hashicorp/nomad/pluginutils/grpcutils"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/grpcutils"
|
||||
"google.golang.org/grpc/status"
|
||||
)
|
||||
|
||||
|
|
|
@ -18,8 +18,8 @@ import (
|
|||
"github.com/hashicorp/hcl2/hcldec"
|
||||
"github.com/hashicorp/nomad/plugins/base"
|
||||
"github.com/hashicorp/nomad/plugins/device"
|
||||
"github.com/hashicorp/nomad/pluginutils/hclspecutils"
|
||||
"github.com/hashicorp/nomad/pluginutils/hclutils"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/hclspecutils"
|
||||
"github.com/hashicorp/nomad/helper/pluginutils/hclutils"
|
||||
"github.com/kr/pretty"
|
||||
"github.com/mitchellh/cli"
|
||||
"github.com/zclconf/go-cty/cty/msgpack"
|
||||
|
|
Loading…
Reference in New Issue