upgrade to latest dependencies (#1362)

bumping knative.dev/networking 53f45d6...ca0a601:
  > ca0a601 Remove deprecated label (# 457)
  > c8ff46f add annotation for setting http option (# 440)
  > b983b72 Update actions (# 456)
  > 6c60e9e upgrade to latest dependencies (# 455)
  > 2315e14 Update community files (# 454)
  > 78822ee Set default HTTPOption to Enabled for conformance test (# 453)
  > 0367556 upgrade to latest dependencies (# 452)
  > be44eda Update community files (# 451)
bumping knative.dev/serving c75484e...d207fa3:
  > d207fa3 upgrade to latest dependencies (# 11622)
  > 6459485 Update net-contour nightly (# 11627)
  > 5f1b6c2 Update net-istio nightly (# 11615)
  > 7da260d Update net-certmanager nightly (# 11628)
  > 3d23011 Remove deprecated label `networking.internal.knative.dev/disableWildcardCert` (# 11626)
  > dbffff6 Update net-kourier nightly (# 11616)
  > 56506cc Update net-certmanager nightly (# 11620)
  > b066a0b Remove unused varlog and observed-concurrency images (# 11619)
  > ad3e890 Update net-contour nightly (# 11614)
  > 657e524 Update actions (# 11613)
  > 98a184b upgrade to latest dependencies (# 11612)
bumping knative.dev/pkg dd0db4b...30f9568:
  > 30f9568 Update actions (# 2177)
  > 51cfaab Added inverse functions for the ptr package (# 2172)
  > cf1994e Update community files (# 2171)
  > 4cdacd0 add concurrency for each controller (# 2160)
  > e117baa Replace reference to obsolete xip.io service (# 2169)
  > a1bc850 Print proper warning logs from API warnings (# 2168)
  > a421cf1 upgrade to latest dependencies (# 2167)
  > 6b252df Update community files (# 2165)
bumping knative.dev/eventing a574b7b...90932eb:
  > 90932eb upgrade to latest dependencies (# 5556)

Signed-off-by: Knative Automation <automation@knative.team>
This commit is contained in:
knative-automation 2021-07-05 23:12:20 -07:00 committed by GitHub
parent 090ba0ceaa
commit 3f424c371e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 166 additions and 25 deletions

8
go.mod
View File

@ -22,11 +22,11 @@ require (
k8s.io/cli-runtime v0.20.7
k8s.io/client-go v0.20.7
k8s.io/code-generator v0.20.7
knative.dev/eventing v0.24.0
knative.dev/eventing v0.24.1-0.20210702080639-90932eb671e0
knative.dev/hack v0.0.0-20210622141627-e28525d8d260
knative.dev/networking v0.0.0-20210622182128-53f45d6d2cfa
knative.dev/pkg v0.0.0-20210622173328-dd0db4b05c80
knative.dev/serving v0.24.0
knative.dev/networking v0.0.0-20210705111547-ca0a601fc900
knative.dev/pkg v0.0.0-20210701025203-30f9568e894e
knative.dev/serving v0.24.1-0.20210705154247-d207fa3a92ac
sigs.k8s.io/yaml v1.2.0
)

20
go.sum
View File

@ -1593,19 +1593,21 @@ k8s.io/utils v0.0.0-20200729134348-d5654de09c73/go.mod h1:jPW/WVKK9YHAvNhRxK0md/
k8s.io/utils v0.0.0-20201110183641-67b214c5f920/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
k8s.io/utils v0.0.0-20210111153108-fddb29f9d009 h1:0T5IaWHO3sJTEmCP6mUlBvMukxPKUQWqiI/YuiBNMiQ=
k8s.io/utils v0.0.0-20210111153108-fddb29f9d009/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA=
knative.dev/caching v0.0.0-20210622183028-95f67e075071/go.mod h1:9gwZcCBtmo9pi1oTgchXcdMNAXAYWklwDmO9uhDsIJE=
knative.dev/eventing v0.24.0 h1:CoaQwZBizxZyOFJUvFcyb7vYSvpYBmfb4IYRNWUdTPE=
knative.dev/eventing v0.24.0/go.mod h1:9xo0SWkIfpXrx0lvGQO7MUlPF8cu+QCMd2gGxj6wxrU=
knative.dev/caching v0.0.0-20210701025702-e6e703d9557b/go.mod h1:RZs6mvIaZendqv7O0ewst35K8o13Wqy5J7oMDjAdiu4=
knative.dev/eventing v0.24.1-0.20210702080639-90932eb671e0 h1:A3/G1uDuRLTU2vYAb8Po9F3CKZ1Svmqk5hfr5/dxTJ8=
knative.dev/eventing v0.24.1-0.20210702080639-90932eb671e0/go.mod h1:93VHah2XghrfrDFr4jSN4KdZS7RtoZuv4qR2Jn2B6x8=
knative.dev/hack v0.0.0-20210622141627-e28525d8d260 h1:f2eMtOubAOc/Q7JlvFPDKXiPlJVK+VpX2Cot8hRzCgQ=
knative.dev/hack v0.0.0-20210622141627-e28525d8d260/go.mod h1:PHt8x8yX5Z9pPquBEfIj0X66f8iWkWfR0S/sarACJrI=
knative.dev/hack/schema v0.0.0-20210622141627-e28525d8d260/go.mod h1:ffjwmdcrH5vN3mPhO8RrF2KfNnbHeCE2C60A+2cv3U0=
knative.dev/networking v0.0.0-20210622182128-53f45d6d2cfa h1:MprAGBX3eRaBZFRXC3ZjsnhnjttfprRVXdxmTeEzC2o=
knative.dev/networking v0.0.0-20210622182128-53f45d6d2cfa/go.mod h1:vwPACNE712tyoEG4fjyUIgfL4xkbXFugx8bxW+QrKn4=
knative.dev/pkg v0.0.0-20210622173328-dd0db4b05c80 h1:GHJ3lglE0/YHfBMMJqluqUNLOmsNXh7s7DBnfrkpRMM=
knative.dev/networking v0.0.0-20210705111547-ca0a601fc900 h1:pjC4YxKR0mH5/GTORkdyN2U2oNoCwICGrX6AReUG0LE=
knative.dev/networking v0.0.0-20210705111547-ca0a601fc900/go.mod h1:lT2n243XZb7K59q4FLtCuAeuboOjoJeLYvTxxfO5rIY=
knative.dev/pkg v0.0.0-20210622173328-dd0db4b05c80/go.mod h1:kGegTnbZ+ljFjAE3E1+8wgaH2LMv8qYi+72o3F3cbdc=
knative.dev/reconciler-test v0.0.0-20210623134345-88c84739abd9/go.mod h1:4wqv2WyWUC5yhTesRUVwgjv/fHTHny1RYBfdB6tVDok=
knative.dev/serving v0.24.0 h1:MZIXR0r2FCXlTuQQXwLuM9+tV6pl2K6YUtK6tEtDB58=
knative.dev/serving v0.24.0/go.mod h1:l/dhsWs+Y8PAssBxaS/hN4HRQQGy4zxfVHD1xYjl3ns=
knative.dev/pkg v0.0.0-20210628225612-51cfaabbcdf6/go.mod h1:kGegTnbZ+ljFjAE3E1+8wgaH2LMv8qYi+72o3F3cbdc=
knative.dev/pkg v0.0.0-20210701025203-30f9568e894e h1:2TofgD72tjBuWN3a4Rg3uzrMu1OWOlh2KY2m0fsjwqQ=
knative.dev/pkg v0.0.0-20210701025203-30f9568e894e/go.mod h1:kGegTnbZ+ljFjAE3E1+8wgaH2LMv8qYi+72o3F3cbdc=
knative.dev/reconciler-test v0.0.0-20210630182710-2a6d91dfee1e/go.mod h1:4wqv2WyWUC5yhTesRUVwgjv/fHTHny1RYBfdB6tVDok=
knative.dev/serving v0.24.1-0.20210705154247-d207fa3a92ac h1:z9xRHZxze66dnlNunH7BwKpBQq4eyyeBJcVvrFRrDAI=
knative.dev/serving v0.24.1-0.20210705154247-d207fa3a92ac/go.mod h1:ktSG08SjDYoGEIPw9GzzS6njQjr6bpWXQuViOOtmLkg=
modernc.org/cc v1.0.0/go.mod h1:1Sk4//wdnYJiUIxnW8ddKpaOJCF37yAdqYnkxUpaYxw=
modernc.org/golex v1.0.0/go.mod h1:b/QX9oBD/LhixY6NDh+IdGv17hgB+51fET1i2kPSmvk=
modernc.org/mathutil v1.0.0/go.mod h1:wU0vUrJsVWBZ4P6e7xtFJEhFSNsfRLJ8H458uRjg03k=

View File

@ -28,6 +28,7 @@ var (
allowedAnnotations = sets.NewString(
DisableAutoTLSAnnotationKey,
CertificateClassAnnotationKey,
HTTPOptionAnnotationKey,
)
)

View File

@ -35,9 +35,14 @@ const (
// Istio-based Ingress will reconcile into a VirtualService).
IngressClassAnnotationKey = "networking.knative.dev/ingress.class"
// DisableAutoTLSAnnotationKey is the label key attached to a namespace to indicate that
// AutoTLS should not be enabled for it.
// DisableAutoTLSAnnotationKey is the annotation key attached to a Knative Service/DomainMapping
// to indicate that AutoTLS should not be enabled for it.
DisableAutoTLSAnnotationKey = "networking.knative.dev/disableAutoTLS"
// HTTPOptionAnnotationKey is the annotation key attached to a Knative Service/DomainMapping
// to indicate the HTTP option of it.
HTTPOptionAnnotationKey = "networking.knative.dev/httpOption"
// IngressLabelKey is the label key attached to underlying network programming
// resources to indicate which Ingress triggered their creation.
IngressLabelKey = GroupName + "/ingress"
@ -69,10 +74,6 @@ const (
// Cert-Manager-based Certificate will reconcile into a Cert-Manager Certificate).
CertificateClassAnnotationKey = "networking.knative.dev/certificate.class"
// DeprecatedDisableWildcardCertLabelKey is the deprecated label key attached to a namespace to indicate that
// a wildcard certificate should be not created for it.
DeprecatedDisableWildcardCertLabelKey = GroupName + "/disableWildcardCert"
// DisableWildcardCertLabelKey is the label key attached to a namespace to indicate that
// a wildcard certificate should be not created for it.
DisableWildcardCertLabelKey = "networking.knative.dev/disableWildcardCert"

View File

@ -57,6 +57,7 @@ var (
// when processing the controller's workqueue. Controller binaries
// may adjust this process-wide default. For finer control, invoke
// Run on the controller directly.
// TODO rename the const to Concurrency and deprecated this
DefaultThreadsPerController = 2
)
@ -203,6 +204,9 @@ type Impl struct {
// which are not required to complete at the highest priority.
workQueue *twoLaneQueue
// Concurrency - The number of workers to use when processing the controller's workqueue.
Concurrency int
// Sugared logger is easier to use but is not as performant as the
// raw logger. In performance critical paths, call logger.Desugar()
// and use the returned raw logger instead. In addition to the
@ -221,6 +225,7 @@ type ControllerOptions struct { //nolint // for backcompat.
Logger *zap.SugaredLogger
Reporter StatsReporter
RateLimiter workqueue.RateLimiter
Concurrency int
}
// NewImpl instantiates an instance of our controller that will feed work to the
@ -244,12 +249,16 @@ func NewImplFull(r Reconciler, options ControllerOptions) *Impl {
if options.Reporter == nil {
options.Reporter = MustNewStatsReporter(options.WorkQueueName, options.Logger)
}
if options.Concurrency == 0 {
options.Concurrency = DefaultThreadsPerController
}
return &Impl{
Name: options.WorkQueueName,
Reconciler: r,
workQueue: newTwoLaneWorkQueue(options.WorkQueueName, options.RateLimiter),
logger: options.Logger,
statsReporter: options.Reporter,
Concurrency: options.Concurrency,
}
}
@ -723,9 +732,10 @@ func StartAll(ctx context.Context, controllers ...*Impl) {
// Start all of the controllers.
for _, ctrlr := range controllers {
wg.Add(1)
concurrency := ctrlr.Concurrency
go func(c *Impl) {
defer wg.Done()
c.RunContext(ctx, DefaultThreadsPerController)
c.RunContext(ctx, concurrency)
}(ctrlr)
}
wg.Wait()

View File

@ -38,6 +38,9 @@ type Options struct {
// DemoteFunc configures the demote function this reconciler uses
DemoteFunc func(b reconciler.Bucket)
// Concurrency - The number of workers to use when processing the controller's workqueue.
Concurrency int
}
// OptionsFn is a callback method signature that accepts an Impl and returns

View File

@ -0,0 +1,33 @@
/*
Copyright 2021 The Knative Authors
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package logging
import "go.uber.org/zap"
// WarningHandler is a warning handler to forward client-go's warning logs into a zap logger.
type WarningHandler struct {
Logger *zap.SugaredLogger
}
func (h *WarningHandler) HandleWarningHeader(code int, agent string, message string) {
// This condition is copied from K8s' default WarningLogger.
if code != 299 || len(message) == 0 {
return
}
h.Logger.Warn("API Warning: " + message)
}

91
vendor/knative.dev/pkg/ptr/value.go vendored Normal file
View File

@ -0,0 +1,91 @@
/*
Copyright 2021 The Knative Authors
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package ptr
import "time"
// Int32Value is a helper for turning pointers to integers into values for use
// in API types that want int32.
func Int32Value(i *int32) int32 {
if i == nil {
return 0
}
return *i
}
// Int64Value is a helper for turning pointers to integers into values for use
// in API types that want int64.
func Int64Value(i *int64) int64 {
if i == nil {
return 0
}
return *i
}
// Float32Value is a helper for turning pointers to floats into values for use
// in API types that want float32.
func Float32Value(f *float32) float32 {
if f == nil {
return 0
}
return *f
}
// Float64Value is a helper for turning pointers to floats into values for use
// in API types that want float64.
func Float64Value(f *float64) float64 {
if f == nil {
return 0
}
return *f
}
// BoolValue is a helper for turning pointers to bools into values for use in
// API types that want bool.
func BoolValue(b *bool) bool {
if b == nil {
return false
}
return *b
}
// StringValue is a helper for turning pointers to strings into values for use
// in API types that want string.
func StringValue(s *string) string {
if s == nil {
return ""
}
return *s
}
// DurationValue is a helper for turning *time.Duration into values for use in
// API types that want time.Duration.
func DurationValue(t *time.Duration) time.Duration {
if t == nil {
return 0
}
return *t
}
// TimeValue is a helper for turning *time.Time into values for use in API
// types that want API types that want time.Time.
func TimeValue(t *time.Time) time.Time {
if t == nil {
return time.Time{}
}
return *t
}

View File

@ -208,7 +208,7 @@ func DefaultErrorRetryChecker(err error) (bool, error) {
if isTCPTimeout(err) {
return true, fmt.Errorf("retrying for TCP timeout: %w", err)
}
// Retrying on DNS error, since we may be using xip.io or nip.io in tests.
// Retrying on DNS error, since we may be using sslip.io or nip.io in tests.
if isDNSError(err) {
return true, fmt.Errorf("retrying for DNS error: %w", err)
}

8
vendor/modules.txt vendored
View File

@ -776,7 +776,7 @@ k8s.io/utils/buffer
k8s.io/utils/integer
k8s.io/utils/pointer
k8s.io/utils/trace
# knative.dev/eventing v0.24.0
# knative.dev/eventing v0.24.1-0.20210702080639-90932eb671e0
## explicit
knative.dev/eventing/pkg/apis/config
knative.dev/eventing/pkg/apis/duck
@ -805,12 +805,12 @@ knative.dev/eventing/pkg/client/clientset/versioned/typed/sources/v1beta2/fake
# knative.dev/hack v0.0.0-20210622141627-e28525d8d260
## explicit
knative.dev/hack
# knative.dev/networking v0.0.0-20210622182128-53f45d6d2cfa
# knative.dev/networking v0.0.0-20210705111547-ca0a601fc900
## explicit
knative.dev/networking/pkg
knative.dev/networking/pkg/apis/networking
knative.dev/networking/pkg/apis/networking/v1alpha1
# knative.dev/pkg v0.0.0-20210622173328-dd0db4b05c80
# knative.dev/pkg v0.0.0-20210701025203-30f9568e894e
## explicit
knative.dev/pkg/apis
knative.dev/pkg/apis/duck
@ -856,7 +856,7 @@ knative.dev/pkg/tracing/propagation
knative.dev/pkg/tracing/propagation/tracecontextb3
knative.dev/pkg/tracker
knative.dev/pkg/unstructured
# knative.dev/serving v0.24.0
# knative.dev/serving v0.24.1-0.20210705154247-d207fa3a92ac
## explicit
knative.dev/serving/pkg/apis/autoscaling
knative.dev/serving/pkg/apis/autoscaling/v1alpha1