1
0
Fork 0
mirror of https://github.com/arangodb/kube-arangodb.git synced 2024-12-14 11:57:37 +00:00

[Linter] Update linter rules to force import ordering (#1044)

This commit is contained in:
Nikita Vanyasin 2022-07-11 14:49:47 +03:00 committed by GitHub
parent a9dee48be1
commit 8ca0835a5d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
429 changed files with 1136 additions and 1157 deletions

View file

@ -24,11 +24,21 @@ linters:
- unused - unused
- varcheck - varcheck
- importas - importas
- gci
linters-settings: linters-settings:
importas: importas:
no-unaliased: true
alias: alias:
- pkg: k8s.io/api/core/v1 - pkg: k8s.io/api/core/v1
alias: core alias: core
- pkg: k8s.io/apimachinery/pkg/apis/meta/v1 - pkg: k8s.io/apimachinery/pkg/apis/meta/v1
alias: meta alias: meta
- pkg: k8s.io/client-go/kubernetes/typed/core/v1
alias: typedCore
gci:
sections:
- standard
- default
- prefix(github.com/arangodb)
- prefix(github.com/arangodb/kube-arangodb)

View file

@ -155,8 +155,9 @@ ifdef VERBOSE
TESTVERBOSEOPTIONS := -v TESTVERBOSEOPTIONS := -v
endif endif
EXCLUDE_DIRS := vendor .gobuild deps tools EXCLUDE_DIRS := vendor .gobuild deps tools pkg/generated
SOURCES_QUERY := find ./ -type f -name '*.go' $(foreach EXCLUDE_DIR,$(EXCLUDE_DIRS), ! -path "*/$(EXCLUDE_DIR)/*") EXCLUDE_FILES := *generated.deepcopy.go
SOURCES_QUERY := find ./ -type f -name '*.go' $(foreach EXCLUDE_DIR,$(EXCLUDE_DIRS), ! -path "*/$(EXCLUDE_DIR)/*") $(foreach EXCLUDE_FILE,$(EXCLUDE_FILES), ! -path "*/$(EXCLUDE_FILE)")
SOURCES := $(shell $(SOURCES_QUERY)) SOURCES := $(shell $(SOURCES_QUERY))
DASHBOARDSOURCES := $(shell find $(DASHBOARDDIR)/src -name '*.js') $(DASHBOARDDIR)/package.json DASHBOARDSOURCES := $(shell find $(DASHBOARDDIR)/src -name '*.js') $(DASHBOARDDIR)/package.json
LINT_EXCLUDES:= LINT_EXCLUDES:=
@ -166,7 +167,6 @@ else
LINT_EXCLUDES+=.*\.enterprise\.go$$ LINT_EXCLUDES+=.*\.enterprise\.go$$
endif endif
.DEFAULT_GOAL := all .DEFAULT_GOAL := all
.PHONY: all .PHONY: all
all: check-vars verify-generated build all: check-vars verify-generated build
@ -191,6 +191,7 @@ license-verify:
fmt: fmt:
@echo ">> Ensuring style of files" @echo ">> Ensuring style of files"
@$(GOPATH)/bin/goimports -w $(SOURCES) @$(GOPATH)/bin/goimports -w $(SOURCES)
@$(GOPATH)/bin/gci write -s "standard" -s "default" -s "prefix(github.com/arangodb)" -s "prefix(github.com/arangodb/kube-arangodb)" $(SOURCES)
.PHONY: license .PHONY: license
license: license:
@ -454,13 +455,15 @@ init: tools update-generated $(BIN) vendor
.PHONY: tools .PHONY: tools
tools: update-vendor tools: update-vendor
@echo ">> Fetching golangci-lint linter" @echo ">> Fetching golangci-lint linter"
@GOBIN=$(GOPATH)/bin go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.42.1 @GOBIN=$(GOPATH)/bin go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.46.2
@echo ">> Fetching goimports" @echo ">> Fetching goimports"
@GOBIN=$(GOPATH)/bin go install golang.org/x/tools/cmd/goimports@0bb7e5c47b1a31f85d4f173edc878a8e049764a5 @GOBIN=$(GOPATH)/bin go install golang.org/x/tools/cmd/goimports@0bb7e5c47b1a31f85d4f173edc878a8e049764a5
@echo ">> Fetching license check" @echo ">> Fetching license check"
@GOBIN=$(GOPATH)/bin go install github.com/google/addlicense@6d92264d717064f28b32464f0f9693a5b4ef0239 @GOBIN=$(GOPATH)/bin go install github.com/google/addlicense@6d92264d717064f28b32464f0f9693a5b4ef0239
@echo ">> Fetching GO Assets Builder" @echo ">> Fetching GO Assets Builder"
@GOBIN=$(GOPATH)/bin go install github.com/jessevdk/go-assets-builder@b8483521738fd2198ecfc378067a4e8a6079f8e5 @GOBIN=$(GOPATH)/bin go install github.com/jessevdk/go-assets-builder@b8483521738fd2198ecfc378067a4e8a6079f8e5
@echo ">> Fetching gci"
@GOBIN=$(GOPATH)/bin go install github.com/daixiang0/gci@v0.3.0
.PHONY: vendor .PHONY: vendor
vendor: vendor:

View file

@ -33,8 +33,6 @@ import (
"strconv" "strconv"
"syscall" "syscall"
"github.com/arangodb/kube-arangodb/pkg/util/globals"
"github.com/spf13/cobra" "github.com/spf13/cobra"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
@ -42,10 +40,12 @@ import (
"github.com/arangodb-helper/go-certificates" "github.com/arangodb-helper/go-certificates"
"github.com/arangodb/go-driver/jwt" "github.com/arangodb/go-driver/jwt"
"github.com/arangodb/go-driver/v2/connection" "github.com/arangodb/go-driver/v2/connection"
api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1" api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util/constants" "github.com/arangodb/kube-arangodb/pkg/util/constants"
"github.com/arangodb/kube-arangodb/pkg/util/errors" "github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util/globals"
"github.com/arangodb/kube-arangodb/pkg/util/k8sutil" "github.com/arangodb/kube-arangodb/pkg/util/k8sutil"
secretv1 "github.com/arangodb/kube-arangodb/pkg/util/k8sutil/inspector/secret/v1" secretv1 "github.com/arangodb/kube-arangodb/pkg/util/k8sutil/inspector/secret/v1"
"github.com/arangodb/kube-arangodb/pkg/util/kclient" "github.com/arangodb/kube-arangodb/pkg/util/kclient"

View file

@ -31,31 +31,7 @@ import (
"strings" "strings"
"time" "time"
"github.com/arangodb/kube-arangodb/pkg/util/globals"
"github.com/gin-gonic/gin" "github.com/gin-gonic/gin"
operatorHTTP "github.com/arangodb/kube-arangodb/pkg/util/http"
"github.com/arangodb/kube-arangodb/pkg/version"
"github.com/arangodb/kube-arangodb/pkg/operator/scope"
"github.com/arangodb/kube-arangodb/pkg/deployment/features"
deploymentApi "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
"github.com/arangodb/kube-arangodb/pkg/crd"
"github.com/arangodb/kube-arangodb/pkg/generated/clientset/versioned/scheme"
"github.com/arangodb/kube-arangodb/pkg/logging"
"github.com/arangodb/kube-arangodb/pkg/operator"
"github.com/arangodb/kube-arangodb/pkg/server"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/constants"
utilsError "github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util/k8sutil"
"github.com/arangodb/kube-arangodb/pkg/util/kclient"
"github.com/arangodb/kube-arangodb/pkg/util/probe"
"github.com/arangodb/kube-arangodb/pkg/util/retry"
"github.com/pkg/errors" "github.com/pkg/errors"
"github.com/rs/zerolog" "github.com/rs/zerolog"
"github.com/spf13/cobra" "github.com/spf13/cobra"
@ -65,9 +41,28 @@ import (
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime"
"k8s.io/client-go/kubernetes" "k8s.io/client-go/kubernetes"
v1core "k8s.io/client-go/kubernetes/typed/core/v1" typedCore "k8s.io/client-go/kubernetes/typed/core/v1"
"k8s.io/client-go/tools/record" "k8s.io/client-go/tools/record"
"k8s.io/klog" "k8s.io/klog"
deploymentApi "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
"github.com/arangodb/kube-arangodb/pkg/crd"
"github.com/arangodb/kube-arangodb/pkg/deployment/features"
"github.com/arangodb/kube-arangodb/pkg/generated/clientset/versioned/scheme"
"github.com/arangodb/kube-arangodb/pkg/logging"
"github.com/arangodb/kube-arangodb/pkg/operator"
"github.com/arangodb/kube-arangodb/pkg/operator/scope"
"github.com/arangodb/kube-arangodb/pkg/server"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/constants"
utilsError "github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util/globals"
operatorHTTP "github.com/arangodb/kube-arangodb/pkg/util/http"
"github.com/arangodb/kube-arangodb/pkg/util/k8sutil"
"github.com/arangodb/kube-arangodb/pkg/util/kclient"
"github.com/arangodb/kube-arangodb/pkg/util/probe"
"github.com/arangodb/kube-arangodb/pkg/util/retry"
"github.com/arangodb/kube-arangodb/pkg/version"
) )
const ( const (
@ -477,7 +472,7 @@ func createRecorder(kubecli kubernetes.Interface, name, namespace string) record
eventBroadcaster.StartLogging(func(format string, args ...interface{}) { eventBroadcaster.StartLogging(func(format string, args ...interface{}) {
eventRecorder.Info(format, args...) eventRecorder.Info(format, args...)
}) })
eventBroadcaster.StartRecordingToSink(&v1core.EventSinkImpl{Interface: v1core.New(kubecli.CoreV1().RESTClient()).Events(namespace)}) eventBroadcaster.StartRecordingToSink(&typedCore.EventSinkImpl{Interface: typedCore.New(kubecli.CoreV1().RESTClient()).Events(namespace)})
combinedScheme := runtime.NewScheme() combinedScheme := runtime.NewScheme()
scheme.AddToScheme(combinedScheme) scheme.AddToScheme(combinedScheme)
core.AddToScheme(combinedScheme) core.AddToScheme(combinedScheme)

View file

@ -28,11 +28,11 @@ import (
"syscall" "syscall"
"time" "time"
"github.com/arangodb/kube-arangodb/pkg/exporter"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/rs/zerolog/log" "github.com/rs/zerolog/log"
"github.com/spf13/cobra" "github.com/spf13/cobra"
"github.com/arangodb/kube-arangodb/pkg/exporter"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
var ( var (

View file

@ -29,19 +29,16 @@ import (
"strconv" "strconv"
"time" "time"
"github.com/arangodb/kube-arangodb/pkg/handlers/utils"
"github.com/arangodb/kube-arangodb/pkg/util/retry"
"github.com/arangodb/kube-arangodb/pkg/version"
"github.com/spf13/cobra" "github.com/spf13/cobra"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/handlers/utils"
"github.com/arangodb/kube-arangodb/pkg/util/constants" "github.com/arangodb/kube-arangodb/pkg/util/constants"
"github.com/arangodb/kube-arangodb/pkg/util/k8sutil" "github.com/arangodb/kube-arangodb/pkg/util/k8sutil"
"github.com/arangodb/kube-arangodb/pkg/util/kclient" "github.com/arangodb/kube-arangodb/pkg/util/kclient"
"github.com/arangodb/kube-arangodb/pkg/util/retry"
"github.com/arangodb/kube-arangodb/pkg/version"
) )
var ( var (

View file

@ -28,13 +28,15 @@ import (
"os" "os"
"path" "path"
"github.com/arangodb/go-driver/jwt"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/deployment/pod"
"github.com/arangodb/kube-arangodb/pkg/util/constants"
"github.com/pkg/errors" "github.com/pkg/errors"
"github.com/rs/zerolog/log" "github.com/rs/zerolog/log"
"github.com/spf13/cobra" "github.com/spf13/cobra"
"github.com/arangodb/go-driver/jwt"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/deployment/pod"
"github.com/arangodb/kube-arangodb/pkg/util/constants"
) )
var ( var (

View file

@ -26,11 +26,11 @@ import (
"os" "os"
"time" "time"
"github.com/spf13/cobra"
v1 "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1" v1 "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/constants" "github.com/arangodb/kube-arangodb/pkg/util/constants"
"github.com/spf13/cobra"
) )
const ( const (

View file

@ -31,7 +31,14 @@ import (
"strings" "strings"
"sync" "sync"
"github.com/pkg/errors"
"github.com/spf13/cobra"
core "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/api/resource"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/fields"
"k8s.io/apimachinery/pkg/util/intstr" "k8s.io/apimachinery/pkg/util/intstr"
"k8s.io/client-go/kubernetes"
deplv1 "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1" deplv1 "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
acli "github.com/arangodb/kube-arangodb/pkg/generated/clientset/versioned" acli "github.com/arangodb/kube-arangodb/pkg/generated/clientset/versioned"
@ -39,13 +46,6 @@ import (
"github.com/arangodb/kube-arangodb/pkg/util/constants" "github.com/arangodb/kube-arangodb/pkg/util/constants"
"github.com/arangodb/kube-arangodb/pkg/util/k8sutil" "github.com/arangodb/kube-arangodb/pkg/util/k8sutil"
"github.com/arangodb/kube-arangodb/pkg/util/kclient" "github.com/arangodb/kube-arangodb/pkg/util/kclient"
"github.com/pkg/errors"
"github.com/spf13/cobra"
core "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/api/resource"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/fields"
"k8s.io/client-go/kubernetes"
) )
var ( var (

View file

@ -26,13 +26,12 @@ import (
"os" "os"
"strconv" "strconv"
"github.com/arangodb/kube-arangodb/pkg/version"
"github.com/spf13/cobra" "github.com/spf13/cobra"
"github.com/arangodb/kube-arangodb/pkg/storage/provisioner" "github.com/arangodb/kube-arangodb/pkg/storage/provisioner"
"github.com/arangodb/kube-arangodb/pkg/storage/provisioner/service" "github.com/arangodb/kube-arangodb/pkg/storage/provisioner/service"
"github.com/arangodb/kube-arangodb/pkg/util/constants" "github.com/arangodb/kube-arangodb/pkg/util/constants"
"github.com/arangodb/kube-arangodb/pkg/version"
) )
var ( var (

View file

@ -23,8 +23,9 @@ package cmd
import ( import (
"fmt" "fmt"
"github.com/arangodb/kube-arangodb/pkg/version"
"github.com/spf13/cobra" "github.com/spf13/cobra"
"github.com/arangodb/kube-arangodb/pkg/version"
) )
func init() { func init() {

View file

@ -21,10 +21,10 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/apps"
batchv1 "k8s.io/api/batch/v1" batchv1 "k8s.io/api/batch/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/apps"
) )
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

View file

@ -21,11 +21,11 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/apps"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/runtime/schema"
"github.com/arangodb/kube-arangodb/pkg/apis/apps"
) )
const ( const (

View file

@ -21,8 +21,9 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/backup"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/backup"
) )
const ( const (

View file

@ -23,10 +23,10 @@ package v1
import ( import (
"fmt" "fmt"
deployment "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
"github.com/arangodb/kube-arangodb/pkg/handlers/utils"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
deployment "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
"github.com/arangodb/kube-arangodb/pkg/handlers/utils"
) )
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

View file

@ -23,8 +23,9 @@ package v1
import ( import (
"time" "time"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/robfig/cron" "github.com/robfig/cron"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
func (a *ArangoBackupPolicy) Validate() error { func (a *ArangoBackupPolicy) Validate() error {

View file

@ -21,8 +21,9 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/handlers/backup/state"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/handlers/backup/state"
) )
const ( const (

View file

@ -21,8 +21,9 @@
package v1 package v1
import ( import (
shared "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
shared "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1"
) )
// ArangoBackupStatus contains the status part of // ArangoBackupStatus contains the status part of

View file

@ -21,10 +21,11 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/backup"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/runtime/schema"
"github.com/arangodb/kube-arangodb/pkg/apis/backup"
) )
const ( const (

View file

@ -21,8 +21,9 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
) )
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

View file

@ -23,9 +23,10 @@ package v1
import ( import (
"runtime" "runtime"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/pkg/errors" "github.com/pkg/errors"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
) )
type ArangoDeploymentArchitecture []ArangoDeploymentArchitectureType type ArangoDeploymentArchitecture []ArangoDeploymentArchitectureType

View file

@ -23,8 +23,9 @@ package v1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestAuthenticationSpecValidate(t *testing.T) { func TestAuthenticationSpecValidate(t *testing.T) {

View file

@ -21,9 +21,8 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
const ( const (

View file

@ -23,9 +23,8 @@ package v1
import ( import (
time "time" time "time"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// ChaosSpec holds configuration for the deployment chaos monkey. // ChaosSpec holds configuration for the deployment chaos monkey.

View file

@ -21,9 +21,9 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
) )
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

View file

@ -21,8 +21,9 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/pkg/errors" "github.com/pkg/errors"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
) )
type ArangoClusterSynchronizationSpec struct { type ArangoClusterSynchronizationSpec struct {

View file

@ -21,9 +21,10 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/util"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
// ConditionType is a strongly typed condition name // ConditionType is a strongly typed condition name

View file

@ -21,9 +21,10 @@
package v1 package v1
import ( import (
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/deployment" "github.com/arangodb/kube-arangodb/pkg/apis/deployment"
"github.com/arangodb/kube-arangodb/pkg/util/errors" "github.com/arangodb/kube-arangodb/pkg/util/errors"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
) )
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

View file

@ -22,9 +22,10 @@
package v1 package v1
import ( import (
core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
core "k8s.io/api/core/v1"
) )
// MetricsAuthenticationSpec contains spec for authentication with arangodb // MetricsAuthenticationSpec contains spec for authentication with arangodb

View file

@ -24,9 +24,8 @@ import (
"net" "net"
"net/url" "net/url"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// ExternalAccessSpec holds configuration for the external access provided for the deployment. // ExternalAccessSpec holds configuration for the external access provided for the deployment.

View file

@ -21,9 +21,9 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/util/errors"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// ExternalAccessType specifies the type of external access provides for the deployment // ExternalAccessType specifies the type of external access provides for the deployment

View file

@ -23,8 +23,9 @@ package v1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestLicenseSpecValidation(t *testing.T) { func TestLicenseSpecValidation(t *testing.T) {

View file

@ -23,13 +23,14 @@ package v1
import ( import (
"time" "time"
core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/types"
driver "github.com/arangodb/go-driver" driver "github.com/arangodb/go-driver"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
) )
// MemberStatus holds the current status of a single member (server) // MemberStatus holds the current status of a single member (server)

View file

@ -25,9 +25,9 @@ import (
"sort" "sort"
"time" "time"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// MemberStatusList is a list of MemberStatus entries // MemberStatusList is a list of MemberStatus entries

View file

@ -21,10 +21,11 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/runtime/schema"
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
) )
const ( const (

View file

@ -23,8 +23,9 @@ package v1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestRocksDBSpecValidate(t *testing.T) { func TestRocksDBSpecValidate(t *testing.T) {

View file

@ -21,9 +21,9 @@
package v1 package v1
import ( import (
"github.com/magiconair/properties/assert"
"testing" "testing"
"github.com/magiconair/properties/assert"
) )
func TestSecretHashes_Equal(t *testing.T) { func TestSecretHashes_Equal(t *testing.T) {

View file

@ -21,11 +21,11 @@
package v1 package v1
import ( import (
core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1" sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1"
"github.com/arangodb/kube-arangodb/pkg/util/errors" "github.com/arangodb/kube-arangodb/pkg/util/errors"
core "k8s.io/api/core/v1"
) )
const ( const (

View file

@ -25,16 +25,14 @@ import (
"strings" "strings"
"time" "time"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/api/resource" "k8s.io/apimachinery/pkg/api/resource"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
arangodOptions "github.com/arangodb/kube-arangodb/pkg/util/arangod/options" arangodOptions "github.com/arangodb/kube-arangodb/pkg/util/arangod/options"
arangosyncOptions "github.com/arangodb/kube-arangodb/pkg/util/arangosync/options" arangosyncOptions "github.com/arangodb/kube-arangodb/pkg/util/arangosync/options"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// ServerGroupShutdownMethod enum of possible shutdown methods // ServerGroupShutdownMethod enum of possible shutdown methods

View file

@ -23,8 +23,9 @@ package v1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestServerGroupSpecValidateCount(t *testing.T) { func TestServerGroupSpecValidateCount(t *testing.T) {

View file

@ -23,13 +23,12 @@ package v1
import ( import (
"fmt" "fmt"
"github.com/arangodb/kube-arangodb/pkg/util/errors" core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1" sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
) )
var ( var (

View file

@ -23,10 +23,10 @@ package v1
import ( import (
"fmt" "fmt"
core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1" sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1"
core "k8s.io/api/core/v1"
) )
type ServerGroupSpecVolumeMounts []ServerGroupSpecVolumeMount type ServerGroupSpecVolumeMounts []ServerGroupSpecVolumeMount

View file

@ -24,10 +24,10 @@ import (
"fmt" "fmt"
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
) )
const ( const (

View file

@ -23,8 +23,9 @@ package v1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestMonitoringSpecValidate(t *testing.T) { func TestMonitoringSpecValidate(t *testing.T) {

View file

@ -21,9 +21,8 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// SyncSpec holds dc2dc replication specific configuration settings // SyncSpec holds dc2dc replication specific configuration settings

View file

@ -23,8 +23,9 @@ package v1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestSyncSpecValidate(t *testing.T) { func TestSyncSpecValidate(t *testing.T) {

View file

@ -23,10 +23,9 @@ package v1
import ( import (
"net" "net"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util/validation" "github.com/arangodb/kube-arangodb/pkg/util/validation"
) )

View file

@ -24,8 +24,9 @@ import (
"testing" "testing"
"time" "time"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestTLSSpecValidate(t *testing.T) { func TestTLSSpecValidate(t *testing.T) {

View file

@ -21,8 +21,9 @@
package v2alpha1 package v2alpha1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
) )
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

View file

@ -23,9 +23,10 @@ package v2alpha1
import ( import (
"runtime" "runtime"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/pkg/errors" "github.com/pkg/errors"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
) )
type ArangoDeploymentArchitecture []ArangoDeploymentArchitectureType type ArangoDeploymentArchitecture []ArangoDeploymentArchitectureType

View file

@ -23,8 +23,9 @@ package v2alpha1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestAuthenticationSpecValidate(t *testing.T) { func TestAuthenticationSpecValidate(t *testing.T) {

View file

@ -21,9 +21,8 @@
package v2alpha1 package v2alpha1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
const ( const (

View file

@ -23,9 +23,8 @@ package v2alpha1
import ( import (
time "time" time "time"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// ChaosSpec holds configuration for the deployment chaos monkey. // ChaosSpec holds configuration for the deployment chaos monkey.

View file

@ -21,9 +21,9 @@
package v2alpha1 package v2alpha1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
) )
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

View file

@ -21,8 +21,9 @@
package v2alpha1 package v2alpha1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/pkg/errors" "github.com/pkg/errors"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
) )
type ArangoClusterSynchronizationSpec struct { type ArangoClusterSynchronizationSpec struct {

View file

@ -21,9 +21,10 @@
package v2alpha1 package v2alpha1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/util"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
// ConditionType is a strongly typed condition name // ConditionType is a strongly typed condition name

View file

@ -21,9 +21,10 @@
package v2alpha1 package v2alpha1
import ( import (
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/deployment" "github.com/arangodb/kube-arangodb/pkg/apis/deployment"
"github.com/arangodb/kube-arangodb/pkg/util/errors" "github.com/arangodb/kube-arangodb/pkg/util/errors"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
) )
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

View file

@ -22,9 +22,10 @@
package v2alpha1 package v2alpha1
import ( import (
core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
core "k8s.io/api/core/v1"
) )
// MetricsAuthenticationSpec contains spec for authentication with arangodb // MetricsAuthenticationSpec contains spec for authentication with arangodb

View file

@ -24,9 +24,8 @@ import (
"net" "net"
"net/url" "net/url"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// ExternalAccessSpec holds configuration for the external access provided for the deployment. // ExternalAccessSpec holds configuration for the external access provided for the deployment.

View file

@ -21,9 +21,9 @@
package v2alpha1 package v2alpha1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/util/errors"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// ExternalAccessType specifies the type of external access provides for the deployment // ExternalAccessType specifies the type of external access provides for the deployment

View file

@ -23,8 +23,9 @@ package v2alpha1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestLicenseSpecValidation(t *testing.T) { func TestLicenseSpecValidation(t *testing.T) {

View file

@ -23,13 +23,14 @@ package v2alpha1
import ( import (
"time" "time"
core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/types"
driver "github.com/arangodb/go-driver" driver "github.com/arangodb/go-driver"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
) )
// MemberStatus holds the current status of a single member (server) // MemberStatus holds the current status of a single member (server)

View file

@ -25,9 +25,9 @@ import (
"sort" "sort"
"time" "time"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// MemberStatusList is a list of MemberStatus entries // MemberStatusList is a list of MemberStatus entries

View file

@ -21,10 +21,11 @@
package v2alpha1 package v2alpha1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/runtime/schema"
"github.com/arangodb/kube-arangodb/pkg/apis/deployment"
) )
const ( const (

View file

@ -23,8 +23,9 @@ package v2alpha1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestRocksDBSpecValidate(t *testing.T) { func TestRocksDBSpecValidate(t *testing.T) {

View file

@ -21,9 +21,9 @@
package v2alpha1 package v2alpha1
import ( import (
"github.com/magiconair/properties/assert"
"testing" "testing"
"github.com/magiconair/properties/assert"
) )
func TestSecretHashes_Equal(t *testing.T) { func TestSecretHashes_Equal(t *testing.T) {

View file

@ -21,11 +21,11 @@
package v2alpha1 package v2alpha1
import ( import (
core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1" sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1"
"github.com/arangodb/kube-arangodb/pkg/util/errors" "github.com/arangodb/kube-arangodb/pkg/util/errors"
core "k8s.io/api/core/v1"
) )
const ( const (

View file

@ -25,16 +25,14 @@ import (
"strings" "strings"
"time" "time"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/api/resource" "k8s.io/apimachinery/pkg/api/resource"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
arangodOptions "github.com/arangodb/kube-arangodb/pkg/util/arangod/options" arangodOptions "github.com/arangodb/kube-arangodb/pkg/util/arangod/options"
arangosyncOptions "github.com/arangodb/kube-arangodb/pkg/util/arangosync/options" arangosyncOptions "github.com/arangodb/kube-arangodb/pkg/util/arangosync/options"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// ServerGroupShutdownMethod enum of possible shutdown methods // ServerGroupShutdownMethod enum of possible shutdown methods

View file

@ -23,8 +23,9 @@ package v2alpha1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestServerGroupSpecValidateCount(t *testing.T) { func TestServerGroupSpecValidateCount(t *testing.T) {

View file

@ -23,13 +23,12 @@ package v2alpha1
import ( import (
"fmt" "fmt"
"github.com/arangodb/kube-arangodb/pkg/util/errors" core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1" sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1"
) )
var ( var (

View file

@ -23,10 +23,10 @@ package v2alpha1
import ( import (
"fmt" "fmt"
core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1" sharedv1 "github.com/arangodb/kube-arangodb/pkg/apis/shared/v1"
core "k8s.io/api/core/v1"
) )
type ServerGroupSpecVolumeMounts []ServerGroupSpecVolumeMount type ServerGroupSpecVolumeMounts []ServerGroupSpecVolumeMount

View file

@ -24,10 +24,10 @@ import (
"fmt" "fmt"
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared"
) )
const ( const (

View file

@ -23,8 +23,9 @@ package v2alpha1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestMonitoringSpecValidate(t *testing.T) { func TestMonitoringSpecValidate(t *testing.T) {

View file

@ -21,9 +21,8 @@
package v2alpha1 package v2alpha1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// SyncSpec holds dc2dc replication specific configuration settings // SyncSpec holds dc2dc replication specific configuration settings

View file

@ -23,8 +23,9 @@ package v2alpha1
import ( import (
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestSyncSpecValidate(t *testing.T) { func TestSyncSpecValidate(t *testing.T) {

View file

@ -23,10 +23,9 @@ package v2alpha1
import ( import (
"net" "net"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util/validation" "github.com/arangodb/kube-arangodb/pkg/util/validation"
) )

View file

@ -24,8 +24,9 @@ import (
"testing" "testing"
"time" "time"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func TestTLSSpecValidate(t *testing.T) { func TestTLSSpecValidate(t *testing.T) {

View file

@ -23,10 +23,9 @@ package v1
import ( import (
"net/url" "net/url"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// EndpointSpec contains the specification used to reach the syncmasters // EndpointSpec contains the specification used to reach the syncmasters

View file

@ -21,10 +21,11 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/replication"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/runtime/schema"
"github.com/arangodb/kube-arangodb/pkg/apis/replication"
) )
const ( const (

View file

@ -21,8 +21,9 @@
package v1 package v1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/replication"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/replication"
) )
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

View file

@ -23,10 +23,9 @@ package v2alpha1
import ( import (
"net/url" "net/url"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// EndpointSpec contains the specification used to reach the syncmasters // EndpointSpec contains the specification used to reach the syncmasters

View file

@ -21,10 +21,11 @@
package v2alpha1 package v2alpha1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/replication"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/runtime/schema"
"github.com/arangodb/kube-arangodb/pkg/apis/replication"
) )
const ( const (

View file

@ -21,8 +21,9 @@
package v2alpha1 package v2alpha1
import ( import (
"github.com/arangodb/kube-arangodb/pkg/apis/replication"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/replication"
) )
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

View file

@ -23,9 +23,9 @@ package v1
import ( import (
"strings" "strings"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"k8s.io/apimachinery/pkg/util/validation" "k8s.io/apimachinery/pkg/util/validation"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
// KubernetesResourceName define name of kubernetes resource including validation function // KubernetesResourceName define name of kubernetes resource including validation function

View file

@ -24,13 +24,15 @@ import (
"context" "context"
"fmt" "fmt"
"github.com/arangodb/go-driver"
"github.com/arangodb/kube-arangodb/pkg/logging"
"github.com/arangodb/kube-arangodb/pkg/util/kclient"
authorization "k8s.io/api/authorization/v1" authorization "k8s.io/api/authorization/v1"
apiextensions "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1" apiextensions "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1"
"k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/api/errors"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/go-driver"
"github.com/arangodb/kube-arangodb/pkg/logging"
"github.com/arangodb/kube-arangodb/pkg/util/kclient"
) )
var logger = logging.Global().RegisterAndGetLogger("crd", logging.Info) var logger = logging.Global().RegisterAndGetLogger("crd", logging.Info)

View file

@ -24,8 +24,9 @@ import (
"context" "context"
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util/kclient"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
"github.com/arangodb/kube-arangodb/pkg/util/kclient"
) )
func Test_Apply(t *testing.T) { func Test_Apply(t *testing.T) {

View file

@ -21,8 +21,9 @@
package crd package crd
import ( import (
"github.com/arangodb/kube-arangodb/pkg/util"
apiextensions "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1" apiextensions "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func init() { func init() {

View file

@ -21,8 +21,9 @@
package crd package crd
import ( import (
"github.com/arangodb/kube-arangodb/pkg/util"
apiextensions "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1" apiextensions "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func init() { func init() {

View file

@ -23,9 +23,11 @@ package crd
import ( import (
"sync" "sync"
"github.com/arangodb/go-driver"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
apiextensions "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1" apiextensions "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1"
"github.com/arangodb/go-driver"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
) )
const Version = "arangodb.com/version" const Version = "arangodb.com/version"

View file

@ -23,8 +23,9 @@ package crd
import ( import (
"testing" "testing"
"github.com/arangodb/go-driver"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
"github.com/arangodb/go-driver"
) )
func Test_Versions(t *testing.T) { func Test_Versions(t *testing.T) {

View file

@ -25,18 +25,16 @@ import (
"strings" "strings"
"time" "time"
"github.com/arangodb/kube-arangodb/pkg/util/globals" "gopkg.in/yaml.v3"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
certificates "github.com/arangodb-helper/go-certificates"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
certificates "github.com/arangodb-helper/go-certificates"
"github.com/arangodb/kube-arangodb/pkg/util/constants" "github.com/arangodb/kube-arangodb/pkg/util/constants"
"github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/arangodb/kube-arangodb/pkg/util/globals"
"github.com/arangodb/kube-arangodb/pkg/util/k8sutil" "github.com/arangodb/kube-arangodb/pkg/util/k8sutil"
"gopkg.in/yaml.v3"
) )
const ( const (

View file

@ -24,11 +24,12 @@ package acs
import ( import (
"context" "context"
"k8s.io/apimachinery/pkg/types"
api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1" api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
"github.com/arangodb/kube-arangodb/pkg/deployment/acs/sutil" "github.com/arangodb/kube-arangodb/pkg/deployment/acs/sutil"
inspectorInterface "github.com/arangodb/kube-arangodb/pkg/util/k8sutil/inspector" inspectorInterface "github.com/arangodb/kube-arangodb/pkg/util/k8sutil/inspector"
"github.com/arangodb/kube-arangodb/pkg/util/kclient" "github.com/arangodb/kube-arangodb/pkg/util/kclient"
"k8s.io/apimachinery/pkg/types"
) )
func NewACS(main types.UID, cache inspectorInterface.Inspector) sutil.ACS { func NewACS(main types.UID, cache inspectorInterface.Inspector) sutil.ACS {

View file

@ -23,10 +23,11 @@ package sutil
import ( import (
"context" "context"
"k8s.io/apimachinery/pkg/types"
api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1" api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
inspectorInterface "github.com/arangodb/kube-arangodb/pkg/util/k8sutil/inspector" inspectorInterface "github.com/arangodb/kube-arangodb/pkg/util/k8sutil/inspector"
"github.com/arangodb/kube-arangodb/pkg/util/kclient" "github.com/arangodb/kube-arangodb/pkg/util/kclient"
"k8s.io/apimachinery/pkg/types"
) )
type ACSGetter interface { type ACSGetter interface {

View file

@ -26,6 +26,7 @@ import (
"github.com/arangodb/go-driver" "github.com/arangodb/go-driver"
"github.com/arangodb/go-driver/agency" "github.com/arangodb/go-driver/agency"
api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1" api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
"github.com/arangodb/kube-arangodb/pkg/generated/metric_descriptions" "github.com/arangodb/kube-arangodb/pkg/generated/metric_descriptions"
"github.com/arangodb/kube-arangodb/pkg/util/errors" "github.com/arangodb/kube-arangodb/pkg/util/errors"

View file

@ -25,9 +25,10 @@ import (
"strings" "strings"
"testing" "testing"
"github.com/arangodb/kube-arangodb/pkg/util"
"github.com/dchest/uniuri" "github.com/dchest/uniuri"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
"github.com/arangodb/kube-arangodb/pkg/util"
) )
func NewDatabaseRandomGenerator() DatabaseGeneratorInterface { func NewDatabaseRandomGenerator() DatabaseGeneratorInterface {

View file

@ -27,6 +27,7 @@ import (
"github.com/arangodb/go-driver" "github.com/arangodb/go-driver"
"github.com/arangodb/go-driver/agency" "github.com/arangodb/go-driver/agency"
"github.com/arangodb/kube-arangodb/pkg/util/errors" "github.com/arangodb/kube-arangodb/pkg/util/errors"
) )

View file

@ -23,9 +23,10 @@ package chaos
import ( import (
"context" "context"
api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
) )
// Context provides methods to the chaos package. // Context provides methods to the chaos package.

View file

@ -25,11 +25,11 @@ import (
"math/rand" "math/rand"
"time" "time"
"github.com/rs/zerolog"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/logging" "github.com/arangodb/kube-arangodb/pkg/logging"
"github.com/arangodb/kube-arangodb/pkg/util/errors" "github.com/arangodb/kube-arangodb/pkg/util/errors"
"github.com/rs/zerolog"
) )
var ( var (

View file

@ -23,13 +23,12 @@ package deployment
import ( import (
"context" "context"
"github.com/arangodb/kube-arangodb/pkg/util/globals"
core "k8s.io/api/core/v1" core "k8s.io/api/core/v1"
meta "k8s.io/apimachinery/pkg/apis/meta/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1"
"github.com/arangodb/kube-arangodb/pkg/util" "github.com/arangodb/kube-arangodb/pkg/util"
"github.com/arangodb/kube-arangodb/pkg/util/constants" "github.com/arangodb/kube-arangodb/pkg/util/constants"
"github.com/arangodb/kube-arangodb/pkg/util/globals"
"github.com/arangodb/kube-arangodb/pkg/util/k8sutil" "github.com/arangodb/kube-arangodb/pkg/util/k8sutil"
inspectorInterface "github.com/arangodb/kube-arangodb/pkg/util/k8sutil/inspector" inspectorInterface "github.com/arangodb/kube-arangodb/pkg/util/k8sutil/inspector"
pvcv1 "github.com/arangodb/kube-arangodb/pkg/util/k8sutil/inspector/persistentvolumeclaim/v1" pvcv1 "github.com/arangodb/kube-arangodb/pkg/util/k8sutil/inspector/persistentvolumeclaim/v1"

View file

@ -28,6 +28,7 @@ import (
driver "github.com/arangodb/go-driver" driver "github.com/arangodb/go-driver"
"github.com/arangodb/go-driver/agency" "github.com/arangodb/go-driver/agency"
api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1" api "github.com/arangodb/kube-arangodb/pkg/apis/deployment/v1"
"github.com/arangodb/kube-arangodb/pkg/apis/shared" "github.com/arangodb/kube-arangodb/pkg/apis/shared"
"github.com/arangodb/kube-arangodb/pkg/deployment/reconciler" "github.com/arangodb/kube-arangodb/pkg/deployment/reconciler"

Some files were not shown because too many files have changed in this diff Show more