Skip to content

Commit

Permalink
.: update go.mod
Browse files Browse the repository at this point in the history
[summary]
Request go version 1.16+
  • Loading branch information
zhyass committed Jul 27, 2021
1 parent 597d5c7 commit d202371
Show file tree
Hide file tree
Showing 9 changed files with 690 additions and 172 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
# vendor/

bin/
testbin/

# ide
.idea
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ vet: ## Run go vet against code.
ENVTEST_ASSETS_DIR=$(shell pwd)/testbin
test: manifests generate fmt vet ## Run tests.
mkdir -p ${ENVTEST_ASSETS_DIR}
test -f ${ENVTEST_ASSETS_DIR}/setup-envtest.sh || curl -sSLo ${ENVTEST_ASSETS_DIR}/setup-envtest.sh https://raw.githubusercontent.com/kubernetes-sigs/controller-runtime/v0.8.3/hack/setup-envtest.sh
test -f ${ENVTEST_ASSETS_DIR}/setup-envtest.sh || curl -sSLo ${ENVTEST_ASSETS_DIR}/setup-envtest.sh https://raw.githubusercontent.com/kubernetes-sigs/controller-runtime/v0.9.2/hack/setup-envtest.sh
source ${ENVTEST_ASSETS_DIR}/setup-envtest.sh; fetch_envtest_tools $(ENVTEST_ASSETS_DIR); setup_envtest_env $(ENVTEST_ASSETS_DIR); go test ./... -coverprofile cover.out

##@ Build
Expand Down
288 changes: 268 additions & 20 deletions charts/mysql-operator/crds/mysql.radondb.com_clusters.yaml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion cluster/syncer/statefulset.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ func (s *StatefulSetSyncer) Sync(ctx context.Context) (syncer.SyncResult, error)
}

// createOrUpdate creates or updates the statefulset in the Kubernetes cluster.
// see https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.8.3/pkg/controller/controllerutil?utm_source=gopls#CreateOrUpdate
// see https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.9.2/pkg/controller/controllerutil?utm_source=gopls#CreateOrUpdate
func (s *StatefulSetSyncer) createOrUpdate(ctx context.Context) (controllerutil.OperationResult, error) {
var err error
if err = s.cli.Get(ctx, client.ObjectKeyFromObject(s.sfs), s.sfs); err != nil {
Expand Down
288 changes: 268 additions & 20 deletions config/crd/bases/mysql.radondb.com_clusters.yaml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion controllers/cluster_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ type ClusterReconciler struct {
// the user.
//
// For more details, check Reconcile and its Result here:
// - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.8.3/pkg/reconcile
// - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.9.2/pkg/reconcile
func (r *ClusterReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) {
log := log.FromContext(ctx).WithName("controllers").WithName("Cluster")
instance := cluster.New(&apiv1alpha1.Cluster{})
Expand Down
2 changes: 1 addition & 1 deletion controllers/status_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ type StatusReconciler struct {
// the user.
//
// For more details, check Reconcile and its Result here:
// - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.8.3/pkg/reconcile
// - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.9.2/pkg/reconcile
func (r *StatusReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) {
log := log.FromContext(ctx).WithName("controllers").WithName("Status")

Expand Down
20 changes: 10 additions & 10 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@ require (
github.com/go-ini/ini v1.62.0
github.com/go-sql-driver/mysql v1.6.0
github.com/iancoleman/strcase v0.0.0-20190422225806-e506e3ef7365
github.com/imdario/mergo v0.3.11
github.com/onsi/ginkgo v1.15.0
github.com/onsi/gomega v1.10.5
github.com/presslabs/controller-util v0.3.0-alpha.2
github.com/imdario/mergo v0.3.12
github.com/onsi/ginkgo v1.16.4
github.com/onsi/gomega v1.13.0
github.com/presslabs/controller-util v0.3.0
github.com/spf13/cobra v1.1.1
github.com/stretchr/testify v1.6.1
k8s.io/api v0.20.4
k8s.io/apimachinery v0.20.4
k8s.io/client-go v0.20.4
k8s.io/klog/v2 v2.4.0
sigs.k8s.io/controller-runtime v0.8.3
github.com/stretchr/testify v1.7.0
k8s.io/api v0.21.2
k8s.io/apimachinery v0.21.2
k8s.io/client-go v0.21.2
k8s.io/klog/v2 v2.8.0
sigs.k8s.io/controller-runtime v0.9.2
)
257 changes: 139 additions & 118 deletions go.sum

Large diffs are not rendered by default.

0 comments on commit d202371

Please sign in to comment.