Skip to content

Commit

Permalink
upgrade to latest dependencies (#1753)
Browse files Browse the repository at this point in the history
bumping knative.dev/serving 6a15707...d0529c2:
  > d0529c2 Update net-certmanager nightly (# 15015)
  > cd1e144 Update net-kourier nightly (# 15017)
bumping knative.dev/eventing b644dad...0604334:
  > 0604334 Replace all usages of deprecated wait.PollImmediate with wait.PollUntilContextTimeout (# 7786)

Signed-off-by: Knative Automation <[email protected]>
  • Loading branch information
knative-automation authored Mar 17, 2024
1 parent 8eb3ba0 commit 8a65909
Show file tree
Hide file tree
Showing 11 changed files with 21 additions and 18 deletions.
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ require (
k8s.io/code-generator v0.29.2
k8s.io/utils v0.0.0-20240102154912-e7106e64919e
knative.dev/caching v0.0.0-20240313151103-e05a25d26a18
knative.dev/eventing v0.40.1-0.20240314073754-b644dad35497
knative.dev/eventing v0.40.1-0.20240315095424-06043341299e
knative.dev/hack v0.0.0-20240313135155-b9f6bf0b323b
knative.dev/pkg v0.0.0-20240313155908-adefab46f5e5
knative.dev/serving v0.40.1-0.20240314174059-6a15707327c8
knative.dev/serving v0.40.1-0.20240315100431-d0529c2c459a
sigs.k8s.io/yaml v1.4.0
)

Expand Down
8 changes: 4 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -1354,16 +1354,16 @@ k8s.io/utils v0.0.0-20240102154912-e7106e64919e h1:eQ/4ljkx21sObifjzXwlPKpdGLrCf
k8s.io/utils v0.0.0-20240102154912-e7106e64919e/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0=
knative.dev/caching v0.0.0-20240313151103-e05a25d26a18 h1:Pi6/UOztJ4VN0Pg3baZYI0LFJMgOpXrhDPHuEkkoSPg=
knative.dev/caching v0.0.0-20240313151103-e05a25d26a18/go.mod h1:eLy+8VDU5MldXfyurwdwRbj+4lSWTbz4EpPnhM535Yg=
knative.dev/eventing v0.40.1-0.20240314073754-b644dad35497 h1:LBgxXZiJXyT07CopDdF3oHhX4KlvoCpi+Yoi7S+bO8A=
knative.dev/eventing v0.40.1-0.20240314073754-b644dad35497/go.mod h1:7RaRYyWlKDCWhSBxvlyqku/Ec1Trp82emUa2AiyP2kc=
knative.dev/eventing v0.40.1-0.20240315095424-06043341299e h1:QFFBe5aKUmJTnlPXVlyX9yMmU+h0dXvWPS3u3HejVMw=
knative.dev/eventing v0.40.1-0.20240315095424-06043341299e/go.mod h1:7RaRYyWlKDCWhSBxvlyqku/Ec1Trp82emUa2AiyP2kc=
knative.dev/hack v0.0.0-20240313135155-b9f6bf0b323b h1:u2D/mdleFeMwjlnMG4ni7vIcaWio8NeYWYtBJe8C6xE=
knative.dev/hack v0.0.0-20240313135155-b9f6bf0b323b/go.mod h1:yk2OjGDsbEnQjfxdm0/HJKS2WqTLEFg/N6nUs6Rqx3Q=
knative.dev/networking v0.0.0-20240312031421-3594f84d0be5 h1:ckn7NhdkxmD14PBEn7yDdOi9WBl2v3xYnrQA+7F5cTA=
knative.dev/networking v0.0.0-20240312031421-3594f84d0be5/go.mod h1:iXWqixPXRe1KJGNhOuydJ+FIbnc3PetpL4kqfnCcZVk=
knative.dev/pkg v0.0.0-20240313155908-adefab46f5e5 h1:zuVGYM92M4Up6v8ficASZMme+pkrIAFbqVGDbVyQ5E8=
knative.dev/pkg v0.0.0-20240313155908-adefab46f5e5/go.mod h1:4BYDECEnyN4FFK5uSyFCz4Wcxww/jLx4f2FL5RwYg/I=
knative.dev/serving v0.40.1-0.20240314174059-6a15707327c8 h1:8u5rqPMgbV52tafcCiicNOur0WU/2wDOiMO/VUrSbC8=
knative.dev/serving v0.40.1-0.20240314174059-6a15707327c8/go.mod h1:Hap8Jqynf4haO0teCc145GK9ChRVDvtugZf/rLTRoBY=
knative.dev/serving v0.40.1-0.20240315100431-d0529c2c459a h1:wJuEtmRgQdKTT/XsgCxHtpnyBv7KWFt8GTgfpHNzZvM=
knative.dev/serving v0.40.1-0.20240315100431-d0529c2c459a/go.mod h1:Hap8Jqynf4haO0teCc145GK9ChRVDvtugZf/rLTRoBY=
nhooyr.io/websocket v1.8.6/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0=
pgregory.net/rapid v1.1.0 h1:CMa0sjHSru3puNx+J0MIAuiiEV4N0qj8/cMWGBBCsjw=
pgregory.net/rapid v1.1.0/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04=
Expand Down
3 changes: 2 additions & 1 deletion vendor/knative.dev/eventing/test/lib/await.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
package lib

import (
"context"
"fmt"
"io"
"net/http"
Expand Down Expand Up @@ -63,7 +64,7 @@ func AwaitForAll(log *zap.SugaredLogger) error {

// WaitForReadiness will wait until readiness endpoint reports OK
func WaitForReadiness(port int, log *zap.SugaredLogger) error {
return wait.PollImmediate(10*time.Millisecond, 5*time.Minute, func() (done bool, err error) {
return wait.PollUntilContextTimeout(context.Background(), 10*time.Millisecond, 5*time.Minute, true, func(ctx context.Context) (done bool, err error) {
resp, err := http.Get(fmt.Sprintf("http://localhost:%d/healthz", port))
if err != nil {
log.Debugf("Error while connecting: %v", err)
Expand Down
5 changes: 3 additions & 2 deletions vendor/knative.dev/eventing/test/lib/duck/resource_checks.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ limitations under the License.
package duck

import (
"context"
"time"

corev1 "k8s.io/api/core/v1"
Expand All @@ -42,14 +43,14 @@ const (
// every interval until isResourceReady returns `true` indicating
// it is done, returns an error or timeout.
func WaitForResourceReady(dynamicClient dynamic.Interface, obj *resources.MetaResource) error {
return wait.PollImmediate(interval, timeout, func() (bool, error) {
return wait.PollUntilContextTimeout(context.Background(), interval, timeout, true, func(ctx context.Context) (bool, error) {
return checkResourceReady(dynamicClient, obj)
})
}

// WaitForResourcesReady waits until all the specified resources in the given namespace are ready.
func WaitForResourcesReady(dynamicClient dynamic.Interface, objList *resources.MetaResourceList) error {
return wait.PollImmediate(interval, timeout, func() (bool, error) {
return wait.PollUntilContextTimeout(context.Background(), interval, timeout, true, func(ctx context.Context) (bool, error) {
return checkResourcesReady(dynamicClient, objList)

})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ func WaitForKServiceScales(ctx context.Context, client resources.ServingClient,

func waitForKServiceDeploymentName(client resources.ServingClient, name, namespace string) (string, error) {
var deploymentName string
err := wait.PollImmediate(interval, timeout, func() (bool, error) {
err := wait.PollUntilContextTimeout(context.Background(), interval, timeout, true, func(ctx context.Context) (bool, error) {
dn, found, err := resources.KServiceDeploymentName(client, name, namespace)
if found {
deploymentName = dn
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ func (ei *EventInfoStore) waitAtLeastNMatch(f EventInfoMatcher, min int) ([]Even
var matchRet []EventInfo
var internalErr error

wait.PollImmediate(retryInterval, retryTimeout, func() (bool, error) {
wait.PollUntilContextTimeout(context.Background(), retryInterval, retryTimeout, true, func(ctx context.Context) (bool, error) {
allMatch, sInfo, matchErrs, err := ei.Find(f)
if err != nil {
internalErr = fmt.Errorf("FAIL MATCHING: unexpected error during find: %v", err)
Expand Down
2 changes: 1 addition & 1 deletion vendor/knative.dev/eventing/test/lib/test_runner.go
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ func SetupPullSecret(t *testing.T, client *Client) {

// waitForServiceAccountExists waits until the ServiceAccount exists.
func waitForServiceAccountExists(client *Client, name, namespace string) error {
return wait.PollImmediate(1*time.Second, 2*time.Minute, func() (bool, error) {
return wait.PollUntilContextTimeout(context.Background(), 1*time.Second, 2*time.Minute, true, func(ctx context.Context) (bool, error) {
sas := client.Kube.CoreV1().ServiceAccounts(namespace)
if _, err := sas.Get(context.Background(), name, metav1.GetOptions{}); err == nil {
return true, nil
Expand Down
2 changes: 1 addition & 1 deletion vendor/knative.dev/eventing/test/lib/tracker.go
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ func (t *Tracker) Clean(awaitDeletion bool) error {
logf("Failed to clean the resource %q : %v", deleter.Name, err)
} else if awaitDeletion {
logf("Waiting for %s to be deleted", deleter.Name)
if err := wait.PollImmediate(interval, timeout, func() (bool, error) {
if err := wait.PollUntilContextTimeout(context.Background(), interval, timeout, true, func(ctx context.Context) (bool, error) {
if _, err := deleter.Resource.Get(context.Background(), deleter.Name, metav1.GetOptions{}); err != nil {
return true, nil
}
Expand Down
3 changes: 2 additions & 1 deletion vendor/knative.dev/eventing/test/upgrade/prober/sender.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
package prober

import (
"context"
"encoding/json"
"fmt"
"time"
Expand Down Expand Up @@ -107,7 +108,7 @@ func (p *prober) removeSender() {
p.ensureNoError(err)

var d *appsv1.Deployment
pollErr := wait.PollImmediate(time.Second, time.Minute, func() (done bool, err error) {
pollErr := wait.PollUntilContextTimeout(context.Background(), time.Second, time.Minute, true, func(ctx context.Context) (done bool, err error) {
// Save err and deployment for error reporting.
d, err = p.client.Kube.AppsV1().
Deployments(p.client.Namespace).
Expand Down
4 changes: 2 additions & 2 deletions vendor/knative.dev/eventing/test/upgrade/prober/verify.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ func (p *prober) Verify() (eventErrs []error, eventsSent int) {
}
p.log.Info("Waiting for complete report from receiver...")
start := time.Now()
if err := wait.PollImmediate(jobWaitInterval, jobWaitTimeout, func() (bool, error) {
if err := wait.PollUntilContextTimeout(context.Background(), jobWaitInterval, jobWaitTimeout, true, func(ctx context.Context) (bool, error) {
var err error
report, err = p.fetchReport()
if err != nil {
Expand Down Expand Up @@ -326,7 +326,7 @@ func waitForJobToComplete(ctx context.Context, client kubernetes.Interface, jobN
span := logging.GetEmitableSpan(ctx, fmt.Sprint("waitForJobToComplete/", jobName))
defer span.End()

return wait.PollImmediate(jobWaitInterval, jobWaitTimeout, func() (bool, error) {
return wait.PollUntilContextTimeout(ctx, jobWaitInterval, jobWaitTimeout, true, func(ctx context.Context) (bool, error) {
j, err := jobs.Get(ctx, jobName, metav1.GetOptions{})
if err != nil {
return true, err
Expand Down
4 changes: 2 additions & 2 deletions vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1314,7 +1314,7 @@ k8s.io/utils/trace
## explicit; go 1.21
knative.dev/caching/pkg/apis/caching
knative.dev/caching/pkg/apis/caching/v1alpha1
# knative.dev/eventing v0.40.1-0.20240314073754-b644dad35497
# knative.dev/eventing v0.40.1-0.20240315095424-06043341299e
## explicit; go 1.21
knative.dev/eventing/pkg/apis/config
knative.dev/eventing/pkg/apis/duck
Expand Down Expand Up @@ -1510,7 +1510,7 @@ knative.dev/pkg/webhook
knative.dev/pkg/webhook/certificates
knative.dev/pkg/webhook/certificates/resources
knative.dev/pkg/webhook/resourcesemantics/conversion
# knative.dev/serving v0.40.1-0.20240314174059-6a15707327c8
# knative.dev/serving v0.40.1-0.20240315100431-d0529c2c459a
## explicit; go 1.21
knative.dev/serving/pkg/apis/autoscaling
knative.dev/serving/pkg/apis/autoscaling/v1alpha1
Expand Down

0 comments on commit 8a65909

Please sign in to comment.