Skip to content

Commit

Permalink
bump go module version to v2 (#1324)
Browse files Browse the repository at this point in the history
Signed-off-by: Zbynek Roubalik <zroubali@redhat.com>
  • Loading branch information
zroubalik authored Nov 18, 2020
1 parent b31d4b6 commit 5c1257d
Show file tree
Hide file tree
Showing 88 changed files with 163 additions and 194 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
### Breaking Changes

### Other
- Bump go module version to v2 ([#1324](https://github.com/kedacore/keda/pull/1324))

## v2.0.0

Expand Down
3 changes: 0 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -233,9 +233,6 @@ clientset-verify: clientset-prepare
.PHONY: clientset-generate
clientset-generate: clientset-prepare
./hack/update-codegen.sh
find ./pkg/generated -type f -name "*.go" |\
xargs sed -i".out" -e "s#github.com/kedacore/keda/api/keda/v1alpha1#github.com/kedacore/keda/api/v1alpha1#g"
find ./pkg/generated -type f -name "*.go.out" | xargs rm -rf
rm -rf api/keda

##################################################
Expand Down
10 changes: 5 additions & 5 deletions adapter/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ import (
basecmd "github.com/kubernetes-incubator/custom-metrics-apiserver/pkg/cmd"
"github.com/kubernetes-incubator/custom-metrics-apiserver/pkg/provider"

kedav1alpha1 "github.com/kedacore/keda/api/v1alpha1"
prommetrics "github.com/kedacore/keda/pkg/metrics"
kedaprovider "github.com/kedacore/keda/pkg/provider"
"github.com/kedacore/keda/pkg/scaling"
"github.com/kedacore/keda/version"
kedav1alpha1 "github.com/kedacore/keda/v2/api/v1alpha1"
prommetrics "github.com/kedacore/keda/v2/pkg/metrics"
kedaprovider "github.com/kedacore/keda/v2/pkg/provider"
"github.com/kedacore/keda/v2/pkg/scaling"
"github.com/kedacore/keda/v2/version"
)

// Adapter creates External Metrics Provider
Expand Down
6 changes: 3 additions & 3 deletions controllers/hpa.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ import (
"fmt"

"github.com/go-logr/logr"
version "github.com/kedacore/keda/version"
version "github.com/kedacore/keda/v2/version"
autoscalingv2beta2 "k8s.io/api/autoscaling/v2beta2"
"k8s.io/apimachinery/pkg/api/equality"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"sigs.k8s.io/controller-runtime/pkg/controller/controllerutil"

kedav1alpha1 "github.com/kedacore/keda/api/v1alpha1"
kedacontrollerutil "github.com/kedacore/keda/controllers/util"
kedav1alpha1 "github.com/kedacore/keda/v2/api/v1alpha1"
kedacontrollerutil "github.com/kedacore/keda/v2/controllers/util"
)

const (
Expand Down
4 changes: 2 additions & 2 deletions controllers/scaledjob_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ import (
"sigs.k8s.io/controller-runtime/pkg/client"
"sigs.k8s.io/controller-runtime/pkg/predicate"

kedav1alpha1 "github.com/kedacore/keda/api/v1alpha1"
"github.com/kedacore/keda/pkg/scaling"
kedav1alpha1 "github.com/kedacore/keda/v2/api/v1alpha1"
"github.com/kedacore/keda/v2/pkg/scaling"
)

// +kubebuilder:rbac:groups=keda.sh,resources=scaledjobs;scaledjobs/finalizers;scaledjobs/status,verbs="*"
Expand Down
4 changes: 2 additions & 2 deletions controllers/scaledjob_finalizer.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (

"github.com/go-logr/logr"

kedav1alpha1 "github.com/kedacore/keda/api/v1alpha1"
"github.com/kedacore/keda/controllers/util"
kedav1alpha1 "github.com/kedacore/keda/v2/api/v1alpha1"
"github.com/kedacore/keda/v2/controllers/util"
)

const (
Expand Down
8 changes: 4 additions & 4 deletions controllers/scaledobject_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ import (
"sigs.k8s.io/controller-runtime/pkg/manager"
"sigs.k8s.io/controller-runtime/pkg/predicate"

kedav1alpha1 "github.com/kedacore/keda/api/v1alpha1"
kedacontrollerutil "github.com/kedacore/keda/controllers/util"
"github.com/kedacore/keda/pkg/scaling"
kedautil "github.com/kedacore/keda/pkg/util"
kedav1alpha1 "github.com/kedacore/keda/v2/api/v1alpha1"
kedacontrollerutil "github.com/kedacore/keda/v2/controllers/util"
"github.com/kedacore/keda/v2/pkg/scaling"
kedautil "github.com/kedacore/keda/v2/pkg/util"
)

// +kubebuilder:rbac:groups=keda.sh,resources=scaledobjects;scaledobjects/finalizers;scaledobjects/status,verbs="*"
Expand Down
4 changes: 2 additions & 2 deletions controllers/scaledobject_finalizer.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"k8s.io/apimachinery/pkg/api/errors"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"

kedav1alpha1 "github.com/kedacore/keda/api/v1alpha1"
"github.com/kedacore/keda/controllers/util"
kedav1alpha1 "github.com/kedacore/keda/v2/api/v1alpha1"
"github.com/kedacore/keda/v2/controllers/util"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion controllers/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import (
"sigs.k8s.io/controller-runtime/pkg/envtest/printer"
logf "sigs.k8s.io/controller-runtime/pkg/log"
"sigs.k8s.io/controller-runtime/pkg/log/zap"
//kedav1alpha1 "github.com/kedacore/keda/api/v1alpha1"
//kedav1alpha1 "github.com/kedacore/keda/v2/api/v1alpha1"
// +kubebuilder:scaffold:imports
)

Expand Down
2 changes: 1 addition & 1 deletion controllers/util/status.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"k8s.io/apimachinery/pkg/runtime"
runtimeclient "sigs.k8s.io/controller-runtime/pkg/client"

kedav1alpha1 "github.com/kedacore/keda/api/v1alpha1"
kedav1alpha1 "github.com/kedacore/keda/v2/api/v1alpha1"
)

// SetStatusConditions patches given object with passed list of conditions based on the object's type or returns an error.
Expand Down
3 changes: 1 addition & 2 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
module github.com/kedacore/keda
module github.com/kedacore/keda/v2

go 1.15

require (
cloud.google.com/go v0.65.0
github.com/Azure/azure-amqp-common-go/v3 v3.1.0
github.com/Azure/azure-event-hubs-go v1.3.1 // indirect
github.com/Azure/azure-event-hubs-go/v3 v3.3.2
github.com/Azure/azure-sdk-for-go v48.0.0+incompatible
github.com/Azure/azure-service-bus-go v0.10.6
Expand Down
Loading

0 comments on commit 5c1257d

Please sign in to comment.