Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade k8s depencencies in host for Openshift 4.16 #1125

Open
wants to merge 14 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions controllers/notification/notification_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ func TestNotificationSuccess(t *testing.T) {
notification, err := notify.NewNotificationBuilder(cl, test.HostOperatorNs).Create(context.TODO(), "[email protected]")
require.NoError(t, err)
notification.Status.Conditions = []toolchainv1alpha1.Condition{sentCond()}
require.NoError(t, cl.Update(context.TODO(), notification))
require.NoError(t, cl.Status().Update(context.TODO(), notification))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just for my understanding, this change is related to dependency update ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good question. These changes are from the previous update of controller-runtime to v0.15 (see here) but missed it last time. This test didn't fail before so this change slipped by, but unit tests were failing now.


// when
result, err := reconcileNotification(controller, notification)
Expand All @@ -74,7 +74,7 @@ func TestNotificationSuccess(t *testing.T) {
require.NoError(t, err)
notification.Status.Conditions = []toolchainv1alpha1.Condition{sentCond()}
notification.Status.Conditions[0].LastTransitionTime = metav1.Time{Time: time.Now().Add(-cast.ToDuration("10s"))}
require.NoError(t, cl.Update(context.TODO(), notification))
require.NoError(t, cl.Status().Update(context.TODO(), notification))

// when
result, err := reconcileNotification(controller, notification)
Expand Down Expand Up @@ -103,7 +103,7 @@ func TestNotificationSentFailure(t *testing.T) {
require.NoError(t, err)
notification.Status.Conditions = []toolchainv1alpha1.Condition{sentCond()}
notification.Status.Conditions[0].LastTransitionTime = metav1.Time{Time: time.Now().Add(-cast.ToDuration("10s"))}
require.NoError(t, cl.Update(context.TODO(), notification))
require.NoError(t, cl.Status().Update(context.TODO(), notification))

// when
result, err := reconcileNotification(controller, notification)
Expand Down
4 changes: 2 additions & 2 deletions controllers/space/space_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ func TestCreateSpace(t *testing.T) {
nsTmplSet.Status.Conditions = []toolchainv1alpha1.Condition{
nstemplatetsettest.Provisioning(),
}
err := member1.Client.Update(context.TODO(), nsTmplSet)
err := member1.Client.Status().Update(context.TODO(), nsTmplSet)
require.NoError(t, err)
ctrl := newReconciler(hostClient, member1, member2)

Expand Down Expand Up @@ -555,7 +555,7 @@ func TestCreateSpace(t *testing.T) {
Name: "john-stage",
},
}
err := member1.Client.Update(context.TODO(), nsTmplSet)
err := member1.Client.Status().Update(context.TODO(), nsTmplSet)
require.NoError(t, err)
ctrl := newReconciler(hostClient, member1)

Expand Down
2 changes: 1 addition & 1 deletion controllers/usersignup/usersignup_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4899,6 +4899,6 @@ func (r *Reconciler) setSpaceToReady(name string) error {
Status: corev1.ConditionTrue,
Reason: toolchainv1alpha1.SpaceProvisionedReason,
})
err = r.Client.Update(context.TODO(), &space)
err = r.Client.Status().Update(context.TODO(), &space)
return err
}
87 changes: 46 additions & 41 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -9,33 +9,33 @@ require (
github.com/go-logr/logr v1.4.1
github.com/gofrs/uuid v4.4.0+incompatible
github.com/mailgun/mailgun-go/v4 v4.8.1
// using latest commit from 'github.com/openshift/api branch release-4.14'
github.com/openshift/api v0.0.0-20241031180523-b1c90a6cf9a3
// using latest commit from 'github.com/openshift/library-go branch release-4.14'
github.com/openshift/library-go v0.0.0-20231213084759-840298df1eee // indirect
// using latest commit from 'github.com/openshift/api branch release-4.16'
github.com/openshift/api v0.0.0-20240830023148-b7d0481c9094
// using latest commit from 'github.com/openshift/library-go branch release-4.16'
github.com/openshift/library-go v0.0.0-20240711192904-190fec8c3f09 // indirect
github.com/pkg/errors v0.9.1
github.com/prometheus/client_golang v1.15.1
github.com/redhat-cop/operator-utils v1.3.6
github.com/prometheus/client_golang v1.18.0
github.com/redhat-cop/operator-utils v1.3.8
github.com/segmentio/analytics-go/v3 v3.2.1
github.com/spf13/cast v1.3.1
github.com/stretchr/testify v1.9.0
go.uber.org/zap v1.24.0
github.com/stretchr/testify v1.10.0
go.uber.org/zap v1.26.0
gopkg.in/h2non/gock.v1 v1.0.14
gopkg.in/yaml.v2 v2.4.0
k8s.io/api v0.27.7
k8s.io/apiextensions-apiserver v0.27.4
k8s.io/apimachinery v0.27.7
k8s.io/client-go v0.27.4
k8s.io/api v0.29.2
k8s.io/apiextensions-apiserver v0.29.2
k8s.io/apimachinery v0.29.2
k8s.io/client-go v0.29.2
k8s.io/klog v1.0.0
k8s.io/klog/v2 v2.100.1
sigs.k8s.io/controller-runtime v0.15.0
k8s.io/klog/v2 v2.110.1
sigs.k8s.io/controller-runtime v0.17.3
)

require (
cloud.google.com/go/auth v0.3.0 // indirect
cloud.google.com/go/auth/oauth2adapt v0.2.2 // indirect
cloud.google.com/go/compute/metadata v0.3.0 // indirect
github.com/BurntSushi/toml v1.2.1 // indirect
github.com/BurntSushi/toml v1.3.2 // indirect
github.com/Masterminds/goutils v1.1.1 // indirect
github.com/Masterminds/semver/v3 v3.2.0 // indirect
github.com/Masterminds/sprig/v3 v3.2.3 // indirect
Expand All @@ -44,21 +44,21 @@ require (
github.com/bmizerany/assert v0.0.0-20160611221934-b7ed37b82869 // indirect
github.com/cespare/xxhash/v2 v2.2.0 // indirect
github.com/cloudflare/circl v1.3.7 // indirect
github.com/emicklei/go-restful/v3 v3.9.0 // indirect
github.com/evanphx/json-patch v5.6.0+incompatible // indirect
github.com/evanphx/json-patch/v5 v5.6.0 // indirect
github.com/emicklei/go-restful/v3 v3.11.0 // indirect
github.com/evanphx/json-patch v5.7.0+incompatible // indirect
github.com/evanphx/json-patch/v5 v5.8.0 // indirect
github.com/exponent-io/jsonpath v0.0.0-20151013193312-d6023ce2651d // indirect
github.com/fsnotify/fsnotify v1.6.0 // indirect
github.com/fsnotify/fsnotify v1.7.0 // indirect
github.com/go-errors/errors v1.4.2 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-logr/zapr v1.2.4 // indirect
github.com/go-logr/zapr v1.3.0 // indirect
github.com/go-openapi/jsonpointer v0.19.6 // indirect
github.com/go-openapi/jsonreference v0.20.2 // indirect
github.com/go-openapi/swag v0.22.3 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/golang/protobuf v1.5.4 // indirect
github.com/google/gnostic v0.5.7-v3refs // indirect
github.com/google/gnostic-models v0.6.8 // indirect
github.com/google/go-cmp v0.6.0 // indirect
github.com/google/go-github/v52 v52.0.0 // indirect
github.com/google/go-querystring v1.1.0 // indirect
Expand All @@ -75,7 +75,7 @@ require (
github.com/josharian/intern v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect
github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 // indirect
github.com/migueleliasweb/go-github-mock v0.0.18 // indirect
github.com/mitchellh/copystructure v1.0.0 // indirect
github.com/mitchellh/reflectwalk v1.0.0 // indirect
Expand All @@ -84,47 +84,52 @@ require (
github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 // indirect
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/prometheus/client_model v0.4.0 // indirect
github.com/prometheus/common v0.42.0 // indirect
github.com/prometheus/procfs v0.9.0 // indirect
github.com/prometheus/client_model v0.5.0 // indirect
github.com/prometheus/common v0.45.0 // indirect
github.com/prometheus/procfs v0.12.0 // indirect
github.com/segmentio/backo-go v1.0.0 // indirect
github.com/shopspring/decimal v1.2.0 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/xlab/treeprint v1.1.0 // indirect
github.com/xlab/treeprint v1.2.0 // indirect
go.opencensus.io v0.24.0 // indirect
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.49.0 // indirect
go.opentelemetry.io/otel v1.24.0 // indirect
go.opentelemetry.io/otel/metric v1.24.0 // indirect
go.opentelemetry.io/otel/trace v1.24.0 // indirect
go.starlark.net v0.0.0-20200306205701-8dd3e2ee1dd5 // indirect
go.uber.org/atomic v1.7.0 // indirect
go.uber.org/multierr v1.6.0 // indirect
go.starlark.net v0.0.0-20230525235612-a134d8f9ddca // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/crypto v0.31.0 // indirect
golang.org/x/net v0.25.0 // indirect
golang.org/x/exp v0.0.0-20220827204233-334a2380cb91 // indirect
golang.org/x/net v0.24.0 // indirect
golang.org/x/oauth2 v0.19.0 // indirect
golang.org/x/sync v0.10.0 // indirect
golang.org/x/sys v0.28.0 // indirect
golang.org/x/term v0.27.0 // indirect
golang.org/x/text v0.21.0 // indirect
golang.org/x/time v0.5.0 // indirect
gomodules.xyz/jsonpatch/v2 v2.3.0 // indirect
gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect
google.golang.org/api v0.177.0 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20240429193739-8cf5692501f6 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240429193739-8cf5692501f6 // indirect
google.golang.org/grpc v1.63.2 // indirect
google.golang.org/protobuf v1.34.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/cli-runtime v0.27.3 // indirect
k8s.io/component-base v0.27.4 // indirect
k8s.io/kube-openapi v0.0.0-20230501164219-8b0f38b5fd1f // indirect
k8s.io/kubectl v0.27.3 // indirect
k8s.io/utils v0.0.0-20230406110748-d93618cff8a2 // indirect
k8s.io/cli-runtime v0.29.2 // indirect
k8s.io/component-base v0.29.2 // indirect
k8s.io/kube-openapi v0.0.0-20231010175941-2dd684a91f00 // indirect
k8s.io/kubectl v0.29.2 // indirect
k8s.io/utils v0.0.0-20230726121419-3b25d923346b // indirect
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
sigs.k8s.io/kustomize/api v0.13.2 // indirect
sigs.k8s.io/kustomize/kyaml v0.14.1 // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect
sigs.k8s.io/yaml v1.3.0 // indirect
sigs.k8s.io/kustomize/api v0.13.5-0.20230601165947-6ce0bf390ce3 // indirect
sigs.k8s.io/kustomize/kyaml v0.14.3-0.20230601165947-6ce0bf390ce3 // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect
sigs.k8s.io/yaml v1.4.0 // indirect
)

go 1.20
go 1.21
ranakan19 marked this conversation as resolved.
Show resolved Hide resolved
ranakan19 marked this conversation as resolved.
Show resolved Hide resolved

replace (
github.com/codeready-toolchain/api v0.0.0-20241119094246-f6581d52dc80 => github.com/ranakan19/api v0.0.0-20250107102252-82f0c9b9a4b9
github.com/codeready-toolchain/toolchain-common v0.0.0-20241128143121-e2e3546a35e9 => github.com/ranakan19/toolchain-common v0.0.0-20250107103332-9c6116d21bd0
)
Loading
Loading