mirror of https://github.com/knative/client.git
upgrade to latest dependencies (#1028)
Signed-off-by: Matt Moore (via Sockpuppet) <mattmoor@vmware.com>
This commit is contained in:
parent
a39903ba78
commit
0bf9aa4746
4
go.mod
4
go.mod
|
|
@ -15,10 +15,10 @@ require (
|
|||
k8s.io/cli-runtime v0.18.8
|
||||
k8s.io/client-go v11.0.1-0.20190805182717-6502b5e7b1b5+incompatible
|
||||
k8s.io/code-generator v0.18.8
|
||||
knative.dev/eventing v0.17.1-0.20200922201940-baa7cd3e8254
|
||||
knative.dev/eventing v0.17.1-0.20200925222044-b313bac67b1c
|
||||
knative.dev/networking v0.0.0-20200922180040-a71b40c69b15
|
||||
knative.dev/pkg v0.0.0-20200922164940-4bf40ad82aab
|
||||
knative.dev/serving v0.17.1-0.20200922232940-9d0250fcaaec
|
||||
knative.dev/serving v0.17.1-0.20200928165745-e46acff3aa54
|
||||
sigs.k8s.io/yaml v1.2.0
|
||||
)
|
||||
|
||||
|
|
|
|||
9
go.sum
9
go.sum
|
|
@ -1889,8 +1889,8 @@ k8s.io/utils v0.0.0-20200603063816-c1c6865ac451/go.mod h1:jPW/WVKK9YHAvNhRxK0md/
|
|||
knative.dev/caching v0.0.0-20190719140829-2032732871ff/go.mod h1:dHXFU6CGlLlbzaWc32g80cR92iuBSpsslDNBWI8C7eg=
|
||||
knative.dev/caching v0.0.0-20200116200605-67bca2c83dfa/go.mod h1:dHXFU6CGlLlbzaWc32g80cR92iuBSpsslDNBWI8C7eg=
|
||||
knative.dev/caching v0.0.0-20200922173540-a6b8bbd6999a/go.mod h1:P624eQ2AZLjwPBRuSqlnkWjRYoVeGdZ/uGXPrYP/USk=
|
||||
knative.dev/eventing v0.17.1-0.20200922201940-baa7cd3e8254 h1:Xdf96eamgMUe6m46S2u2WGPVf2ZCMWSNrpkts8NF/QE=
|
||||
knative.dev/eventing v0.17.1-0.20200922201940-baa7cd3e8254/go.mod h1:5WylXx2ZK+OI7Yb2vQ5uOUlODyd99GEKkWGKQOSvofY=
|
||||
knative.dev/eventing v0.17.1-0.20200925222044-b313bac67b1c h1:ML5wvKKTEX2Btud65Dl6v+HvDTKX8lIcQCWvSBRSH2U=
|
||||
knative.dev/eventing v0.17.1-0.20200925222044-b313bac67b1c/go.mod h1:Rv5V1Sk/XeG6vdEpRu+zDhEUDg2SgbkOJWRNssUyt50=
|
||||
knative.dev/eventing-contrib v0.6.1-0.20190723221543-5ce18048c08b/go.mod h1:SnXZgSGgMSMLNFTwTnpaOH7hXDzTFtw0J8OmHflNx3g=
|
||||
knative.dev/eventing-contrib v0.11.2/go.mod h1:SnXZgSGgMSMLNFTwTnpaOH7hXDzTFtw0J8OmHflNx3g=
|
||||
knative.dev/networking v0.0.0-20200922180040-a71b40c69b15 h1:UhUyfzy5VTEdkWXlkJAKLDPkPK9MKNpENfn17rlYtcs=
|
||||
|
|
@ -1903,11 +1903,10 @@ knative.dev/pkg v0.0.0-20200505191044-3da93ebb24c2/go.mod h1:Q6sL35DdGs8hIQZKdaC
|
|||
knative.dev/pkg v0.0.0-20200515002500-16d7b963416f/go.mod h1:tMOHGbxtRz8zYFGEGpV/bpoTEM1o89MwYFC4YJXl3GY=
|
||||
knative.dev/pkg v0.0.0-20200528142800-1c6815d7e4c9/go.mod h1:QgNZTxnwpB/oSpNcfnLVlw+WpEwwyKAvJlvR3hgeltA=
|
||||
knative.dev/pkg v0.0.0-20200711004937-22502028e31a/go.mod h1:AqAJV6rYi8IGikDjJ/9ZQd9qKdkXVlesVnVjwx62YB8=
|
||||
knative.dev/pkg v0.0.0-20200921223636-6a12c7596267/go.mod h1:MCyt5KqLaai6ENUitOgRAQsu7Gw7cAIIiXQ2IS+O0NI=
|
||||
knative.dev/pkg v0.0.0-20200922164940-4bf40ad82aab h1:4Q+sGqdN4ecLPZnIJcLDdQArEE9oOtRYiU2J6NPCCjU=
|
||||
knative.dev/pkg v0.0.0-20200922164940-4bf40ad82aab/go.mod h1:MCyt5KqLaai6ENUitOgRAQsu7Gw7cAIIiXQ2IS+O0NI=
|
||||
knative.dev/serving v0.17.1-0.20200922232940-9d0250fcaaec h1:LZfqA3xNuK4ATxa448btwexqVkgt0xbv5ETCsUkEd/c=
|
||||
knative.dev/serving v0.17.1-0.20200922232940-9d0250fcaaec/go.mod h1:9U9j3D5yT7nPyVQFp4cnYugbqxF9LbHZVaxCOhNajFI=
|
||||
knative.dev/serving v0.17.1-0.20200928165745-e46acff3aa54 h1:aA5hcRcfo7ksuXDBsoy8ZPUgGZAfbZTGE4wmmJrYsWE=
|
||||
knative.dev/serving v0.17.1-0.20200928165745-e46acff3aa54/go.mod h1:9U9j3D5yT7nPyVQFp4cnYugbqxF9LbHZVaxCOhNajFI=
|
||||
knative.dev/test-infra v0.0.0-20200407185800-1b88cb3b45a5/go.mod h1:xcdUkMJrLlBswIZqL5zCuBFOC22WIPMQoVX1L35i0vQ=
|
||||
knative.dev/test-infra v0.0.0-20200505052144-5ea2f705bb55/go.mod h1:WqF1Azka+FxPZ20keR2zCNtiQA1MP9ZB4BH4HuI+SIU=
|
||||
knative.dev/test-infra v0.0.0-20200513011557-d03429a76034/go.mod h1:aMif0KXL4g19YCYwsy4Ocjjz5xgPlseYV+B95Oo4JGE=
|
||||
|
|
|
|||
|
|
@ -124,9 +124,7 @@ function markdown_build_tests() {
|
|||
(( DISABLE_MD_LINTING && DISABLE_MD_LINK_CHECK )) && return 0
|
||||
# Get changed markdown files (ignore /vendor, github templates, and deleted files)
|
||||
local mdfiles=""
|
||||
# Exclude scripts/test-infra as it is directly imported from test-infra repo which could
|
||||
# have the link with relative path of test-infra repo which does not work with client repo.
|
||||
for file in $(echo "${CHANGED_FILES}" | grep \\.md$ | grep -v ^vendor/ | grep -v ^.github/ | grep =v ^scripts/test-infra); do
|
||||
for file in $(echo "${CHANGED_FILES}" | grep \\.md$ | grep -v ^vendor/ | grep -v ^.github/); do
|
||||
[[ -f "${file}" ]] && mdfiles="${mdfiles} ${file}"
|
||||
done
|
||||
[[ -z "${mdfiles}" ]] && return 0
|
||||
|
|
|
|||
|
|
@ -41,6 +41,7 @@ var FuzzerFuncs = fuzzer.MergeFuzzerFuncs(
|
|||
if ds.BackoffPolicy != nil && *ds.BackoffPolicy == "" {
|
||||
ds.BackoffPolicy = nil
|
||||
} else {
|
||||
// nolint:gosec // Cryptographic randomness is not necessary.
|
||||
ds.BackoffPolicy = bops[rand.Intn(3)]
|
||||
}
|
||||
},
|
||||
|
|
|
|||
|
|
@ -136,8 +136,8 @@ func (sink *SubscribableSpec) ConvertFrom(ctx context.Context, obj apis.Converti
|
|||
case *eventingduckv1.SubscribableSpec:
|
||||
if len(source.Subscribers) > 0 {
|
||||
sink.Subscribers = make([]SubscriberSpec, len(source.Subscribers))
|
||||
for i, s := range source.Subscribers {
|
||||
if err := sink.Subscribers[i].ConvertFrom(ctx, &s); err != nil {
|
||||
for i := range source.Subscribers {
|
||||
if err := sink.Subscribers[i].ConvertFrom(ctx, &source.Subscribers[i]); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
|
@ -172,9 +172,9 @@ func (sink *SubscribableStatus) ConvertFrom(ctx context.Context, obj apis.Conver
|
|||
case *eventingduckv1.SubscribableStatus:
|
||||
if len(source.Subscribers) > 0 {
|
||||
sink.Subscribers = make([]SubscriberStatus, len(source.Subscribers))
|
||||
for i, ss := range source.Subscribers {
|
||||
for i := range source.Subscribers {
|
||||
sink.Subscribers[i] = SubscriberStatus{}
|
||||
if err := sink.Subscribers[i].ConvertFrom(ctx, &ss); err != nil {
|
||||
if err := sink.Subscribers[i].ConvertFrom(ctx, &source.Subscribers[i]); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,8 +38,8 @@ func (cs *ContainerSourceSpec) Validate(ctx context.Context) *apis.FieldError {
|
|||
fe := apis.ErrMissingField("containers")
|
||||
errs = errs.Also(fe)
|
||||
} else {
|
||||
for i, c := range cs.Template.Spec.Containers {
|
||||
if ce := isValidContainer(&c); ce != nil {
|
||||
for i := range cs.Template.Spec.Containers {
|
||||
if ce := isValidContainer(&cs.Template.Spec.Containers[i]); ce != nil {
|
||||
errs = errs.Also(ce.ViaFieldIndex("containers", i))
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,8 +38,8 @@ func (cs *ContainerSourceSpec) Validate(ctx context.Context) *apis.FieldError {
|
|||
fe := apis.ErrMissingField("containers")
|
||||
errs = errs.Also(fe)
|
||||
} else {
|
||||
for i, c := range cs.Template.Spec.Containers {
|
||||
if ce := isValidContainer(&c); ce != nil {
|
||||
for i := range cs.Template.Spec.Containers {
|
||||
if ce := isValidContainer(&cs.Template.Spec.Containers[i]); ce != nil {
|
||||
errs = errs.Also(ce.ViaFieldIndex("containers", i))
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,23 +26,24 @@ import (
|
|||
"knative.dev/pkg/apis"
|
||||
)
|
||||
|
||||
func getIntGE0(m map[string]string, k string) (int64, *apis.FieldError) {
|
||||
func getIntGE0(m map[string]string, k string) (int32, *apis.FieldError) {
|
||||
v, ok := m[k]
|
||||
if !ok {
|
||||
return 0, nil
|
||||
}
|
||||
// Parsing as uint gives a bad format error, rather than invalid range, unfortunately.
|
||||
i, err := strconv.ParseInt(v, 10, 32)
|
||||
if err == nil && i < 0 {
|
||||
return 0, apis.ErrOutOfBoundsValue(v, 0, math.MaxInt32, k)
|
||||
}
|
||||
if err != nil {
|
||||
if nerr, ok := err.(*strconv.NumError); ok && nerr.Err == strconv.ErrRange {
|
||||
return 0, apis.ErrOutOfBoundsValue(v, 0, math.MaxInt32, k)
|
||||
}
|
||||
return 0, apis.ErrInvalidValue(v, k)
|
||||
}
|
||||
if i < 0 {
|
||||
return 0, apis.ErrOutOfBoundsValue(v, 0, math.MaxInt32, k)
|
||||
}
|
||||
|
||||
return i, nil
|
||||
return int32(i), nil
|
||||
}
|
||||
|
||||
// ValidateAnnotations verifies the autoscaling annotations.
|
||||
|
|
@ -64,8 +65,7 @@ func validateClass(annotations map[string]string) *apis.FieldError {
|
|||
return nil
|
||||
}
|
||||
|
||||
func validateFloats(annotations map[string]string) *apis.FieldError {
|
||||
var errs *apis.FieldError
|
||||
func validateFloats(annotations map[string]string) (errs *apis.FieldError) {
|
||||
if v, ok := annotations[PanicWindowPercentageAnnotationKey]; ok {
|
||||
if fv, err := strconv.ParseFloat(v, 64); err != nil {
|
||||
errs = errs.Also(apis.ErrInvalidValue(v, PanicWindowPercentageAnnotationKey))
|
||||
|
|
@ -106,32 +106,33 @@ func validateFloats(annotations map[string]string) *apis.FieldError {
|
|||
}
|
||||
|
||||
func validateLastPodRetention(annotations map[string]string) *apis.FieldError {
|
||||
var errs *apis.FieldError
|
||||
if w, ok := annotations[ScaleToZeroPodRetentionPeriodKey]; ok {
|
||||
if d, err := time.ParseDuration(w); err != nil {
|
||||
errs = apis.ErrInvalidValue(w, ScaleToZeroPodRetentionPeriodKey)
|
||||
return apis.ErrInvalidValue(w, ScaleToZeroPodRetentionPeriodKey)
|
||||
} else if d < 0 || d > WindowMax {
|
||||
// Since we disallow windows longer than WindowMax, so we should limit this
|
||||
// as well.
|
||||
errs = apis.ErrOutOfBoundsValue(w, 0*time.Second, WindowMax, ScaleToZeroPodRetentionPeriodKey)
|
||||
return apis.ErrOutOfBoundsValue(w, time.Duration(0), WindowMax, ScaleToZeroPodRetentionPeriodKey)
|
||||
}
|
||||
}
|
||||
return errs
|
||||
return nil
|
||||
}
|
||||
|
||||
func validateWindow(annotations map[string]string) *apis.FieldError {
|
||||
var errs *apis.FieldError
|
||||
if w, ok := annotations[WindowAnnotationKey]; ok {
|
||||
if annotations[ClassAnnotationKey] == HPA && annotations[MetricAnnotationKey] == CPU {
|
||||
return apis.ErrInvalidKeyName(WindowAnnotationKey, apis.CurrentField, fmt.Sprintf("%s for %s %s", HPA, MetricAnnotationKey, CPU))
|
||||
}
|
||||
if d, err := time.ParseDuration(w); err != nil {
|
||||
errs = apis.ErrInvalidValue(w, WindowAnnotationKey)
|
||||
} else if d < WindowMin || d > WindowMax {
|
||||
errs = apis.ErrOutOfBoundsValue(w, WindowMin, WindowMax, WindowAnnotationKey)
|
||||
switch d, err := time.ParseDuration(w); {
|
||||
case err != nil:
|
||||
return apis.ErrInvalidValue(w, WindowAnnotationKey)
|
||||
case d < WindowMin || d > WindowMax:
|
||||
return apis.ErrOutOfBoundsValue(w, WindowMin, WindowMax, WindowAnnotationKey)
|
||||
case d.Truncate(time.Second) != d:
|
||||
return apis.ErrGeneric("must be specified with at most second precision", WindowAnnotationKey)
|
||||
}
|
||||
}
|
||||
return errs
|
||||
return nil
|
||||
}
|
||||
|
||||
func validateMinMaxScale(annotations map[string]string) *apis.FieldError {
|
||||
|
|
|
|||
|
|
@ -80,17 +80,17 @@ type DeprecatedRevisionServingStateType string
|
|||
|
||||
const (
|
||||
// DeprecatedRevisionServingStateActive is set when the revision is ready to
|
||||
// serve traffic. It should have Kubernetes resources, and the Istio route
|
||||
// serve traffic. It should have Kubernetes resources, and the network
|
||||
// should be pointed to the given resources.
|
||||
DeprecatedRevisionServingStateActive DeprecatedRevisionServingStateType = "Active"
|
||||
// DeprecatedRevisionServingStateReserve is set when the revision is not
|
||||
// currently serving traffic, but could be made to serve traffic quickly. It
|
||||
// should have Kubernetes resources, but the Istio route should be pointed to
|
||||
// should have Kubernetes resources, but the network should be pointed to
|
||||
// the activator.
|
||||
DeprecatedRevisionServingStateReserve DeprecatedRevisionServingStateType = "Reserve"
|
||||
// DeprecatedRevisionServingStateRetired is set when the revision has been
|
||||
// decommissioned and is not needed to serve traffic anymore. It should not
|
||||
// have any Istio routes or Kubernetes resources. A Revision may be brought
|
||||
// have any network or Kubernetes resources. A Revision may be brought
|
||||
// out of retirement, but it may take longer than it would from a "Reserve"
|
||||
// state.
|
||||
// Note: currently not set anywhere. See https://github.com/knative/serving/issues/1203
|
||||
|
|
|
|||
|
|
@ -653,7 +653,7 @@ k8s.io/kube-openapi/pkg/util/sets
|
|||
k8s.io/utils/buffer
|
||||
k8s.io/utils/integer
|
||||
k8s.io/utils/trace
|
||||
# knative.dev/eventing v0.17.1-0.20200922201940-baa7cd3e8254
|
||||
# knative.dev/eventing v0.17.1-0.20200925222044-b313bac67b1c
|
||||
## explicit
|
||||
knative.dev/eventing/pkg/apis/config
|
||||
knative.dev/eventing/pkg/apis/configs
|
||||
|
|
@ -714,7 +714,7 @@ knative.dev/pkg/tracing/config
|
|||
knative.dev/pkg/tracing/propagation
|
||||
knative.dev/pkg/tracing/propagation/tracecontextb3
|
||||
knative.dev/pkg/tracker
|
||||
# knative.dev/serving v0.17.1-0.20200922232940-9d0250fcaaec
|
||||
# knative.dev/serving v0.17.1-0.20200928165745-e46acff3aa54
|
||||
## explicit
|
||||
knative.dev/serving/pkg/apis/autoscaling
|
||||
knative.dev/serving/pkg/apis/autoscaling/v1alpha1
|
||||
|
|
|
|||
Loading…
Reference in New Issue