Move storage, mesos, global container integrations under cmd/internal
This commit is contained in:
parent
d4cce1c12a
commit
855ad76125
@ -35,7 +35,7 @@ import (
|
|||||||
"github.com/google/cadvisor/version"
|
"github.com/google/cadvisor/version"
|
||||||
|
|
||||||
// Register container providers
|
// Register container providers
|
||||||
_ "github.com/google/cadvisor/container/install"
|
_ "github.com/google/cadvisor/cmd/internal/container/install"
|
||||||
|
|
||||||
// Register CloudProviders
|
// Register CloudProviders
|
||||||
_ "github.com/google/cadvisor/utils/cloudinfo/aws"
|
_ "github.com/google/cadvisor/utils/cloudinfo/aws"
|
||||||
|
@ -16,9 +16,9 @@
|
|||||||
package install
|
package install
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
_ "github.com/google/cadvisor/cmd/internal/container/mesos/install"
|
||||||
_ "github.com/google/cadvisor/container/containerd/install"
|
_ "github.com/google/cadvisor/container/containerd/install"
|
||||||
_ "github.com/google/cadvisor/container/crio/install"
|
_ "github.com/google/cadvisor/container/crio/install"
|
||||||
_ "github.com/google/cadvisor/container/docker/install"
|
_ "github.com/google/cadvisor/container/docker/install"
|
||||||
_ "github.com/google/cadvisor/container/mesos/install"
|
|
||||||
_ "github.com/google/cadvisor/container/systemd/install"
|
_ "github.com/google/cadvisor/container/systemd/install"
|
||||||
)
|
)
|
@ -16,8 +16,8 @@
|
|||||||
package install
|
package install
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"github.com/google/cadvisor/cmd/internal/container/mesos"
|
||||||
"github.com/google/cadvisor/container"
|
"github.com/google/cadvisor/container"
|
||||||
"github.com/google/cadvisor/container/mesos"
|
|
||||||
"k8s.io/klog"
|
"k8s.io/klog"
|
||||||
)
|
)
|
||||||
|
|
@ -17,9 +17,9 @@ package bigquery
|
|||||||
import (
|
import (
|
||||||
"os"
|
"os"
|
||||||
|
|
||||||
|
"github.com/google/cadvisor/cmd/internal/storage/bigquery/client"
|
||||||
info "github.com/google/cadvisor/info/v1"
|
info "github.com/google/cadvisor/info/v1"
|
||||||
"github.com/google/cadvisor/storage"
|
"github.com/google/cadvisor/storage"
|
||||||
"github.com/google/cadvisor/storage/bigquery/client"
|
|
||||||
|
|
||||||
bigquery "google.golang.org/api/bigquery/v2"
|
bigquery "google.golang.org/api/bigquery/v2"
|
||||||
)
|
)
|
@ -20,7 +20,7 @@ import (
|
|||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/SeanDolphin/bqschema"
|
"github.com/SeanDolphin/bqschema"
|
||||||
"github.com/google/cadvisor/storage/bigquery/client"
|
"github.com/google/cadvisor/cmd/internal/storage/bigquery/client"
|
||||||
)
|
)
|
||||||
|
|
||||||
type container struct {
|
type container struct {
|
@ -25,9 +25,9 @@ import (
|
|||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
|
"github.com/google/cadvisor/cmd/internal/storage/test"
|
||||||
info "github.com/google/cadvisor/info/v1"
|
info "github.com/google/cadvisor/info/v1"
|
||||||
"github.com/google/cadvisor/storage"
|
"github.com/google/cadvisor/storage"
|
||||||
"github.com/google/cadvisor/storage/test"
|
|
||||||
|
|
||||||
influxdb "github.com/influxdb/influxdb/client"
|
influxdb "github.com/influxdb/influxdb/client"
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
@ -15,9 +15,9 @@
|
|||||||
package statsd
|
package statsd
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
client "github.com/google/cadvisor/cmd/internal/storage/statsd/client"
|
||||||
info "github.com/google/cadvisor/info/v1"
|
info "github.com/google/cadvisor/info/v1"
|
||||||
"github.com/google/cadvisor/storage"
|
"github.com/google/cadvisor/storage"
|
||||||
client "github.com/google/cadvisor/storage/statsd/client"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func init() {
|
func init() {
|
@ -21,14 +21,14 @@ import (
|
|||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/google/cadvisor/cache/memory"
|
"github.com/google/cadvisor/cache/memory"
|
||||||
|
_ "github.com/google/cadvisor/cmd/internal/storage/bigquery"
|
||||||
|
_ "github.com/google/cadvisor/cmd/internal/storage/elasticsearch"
|
||||||
|
_ "github.com/google/cadvisor/cmd/internal/storage/influxdb"
|
||||||
|
_ "github.com/google/cadvisor/cmd/internal/storage/kafka"
|
||||||
|
_ "github.com/google/cadvisor/cmd/internal/storage/redis"
|
||||||
|
_ "github.com/google/cadvisor/cmd/internal/storage/statsd"
|
||||||
|
_ "github.com/google/cadvisor/cmd/internal/storage/stdout"
|
||||||
"github.com/google/cadvisor/storage"
|
"github.com/google/cadvisor/storage"
|
||||||
_ "github.com/google/cadvisor/storage/bigquery"
|
|
||||||
_ "github.com/google/cadvisor/storage/elasticsearch"
|
|
||||||
_ "github.com/google/cadvisor/storage/influxdb"
|
|
||||||
_ "github.com/google/cadvisor/storage/kafka"
|
|
||||||
_ "github.com/google/cadvisor/storage/redis"
|
|
||||||
_ "github.com/google/cadvisor/storage/statsd"
|
|
||||||
_ "github.com/google/cadvisor/storage/stdout"
|
|
||||||
|
|
||||||
"k8s.io/klog"
|
"k8s.io/klog"
|
||||||
)
|
)
|
||||||
|
@ -36,7 +36,12 @@ import (
|
|||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
clock "k8s.io/utils/clock/testing"
|
clock "k8s.io/utils/clock/testing"
|
||||||
|
|
||||||
_ "github.com/google/cadvisor/container/install"
|
// install all the container runtimes included in the library version for testing.
|
||||||
|
// as these are moved to cmd/internal/container, remove them from here.
|
||||||
|
_ "github.com/google/cadvisor/container/containerd/install"
|
||||||
|
_ "github.com/google/cadvisor/container/crio/install"
|
||||||
|
_ "github.com/google/cadvisor/container/docker/install"
|
||||||
|
_ "github.com/google/cadvisor/container/systemd/install"
|
||||||
)
|
)
|
||||||
|
|
||||||
// TODO(vmarmol): Refactor these tests.
|
// TODO(vmarmol): Refactor these tests.
|
||||||
|
Loading…
Reference in New Issue
Block a user