Skip to content

Commit bc5f4be

Browse files
upgrade to latest dependencies (#1049)
bumping knative.dev/eventing 1f9f4d3...4d6e1fc: > 4d6e1fc Change subscription patch logic to ensure resource version (# 6670) > 74e165a APIServerSource with selector to target namespaces (# 6665) Signed-off-by: Knative Automation <[email protected]> Signed-off-by: Knative Automation <[email protected]>
1 parent 595b2b9 commit bc5f4be

File tree

7 files changed

+41
-5
lines changed

7 files changed

+41
-5
lines changed

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ require (
2121
k8s.io/client-go v0.25.4
2222
k8s.io/code-generator v0.25.4
2323
k8s.io/kube-openapi v0.0.0-20220803162953-67bda5d908f1
24-
knative.dev/eventing v0.35.1-0.20230125080738-1f9f4d37aa56
24+
knative.dev/eventing v0.36.0
2525
knative.dev/hack v0.0.0-20230113013652-c7cfcb062de9
2626
knative.dev/pkg v0.0.0-20230117181655-247510c00e9d
2727
knative.dev/reconciler-test v0.0.0-20230123181139-476a442e3644

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1054,8 +1054,8 @@ k8s.io/kube-openapi v0.0.0-20220803162953-67bda5d908f1 h1:MQ8BAZPZlWk3S9K4a9NCkI
10541054
k8s.io/kube-openapi v0.0.0-20220803162953-67bda5d908f1/go.mod h1:C/N6wCaBHeBHkHUesQOQy2/MZqGgMAFPqGsGQLdbZBU=
10551055
k8s.io/utils v0.0.0-20221108210102-8e77b1f39fe2 h1:GfD9OzL11kvZN5iArC6oTS7RTj7oJOIfnislxYlqTj8=
10561056
k8s.io/utils v0.0.0-20221108210102-8e77b1f39fe2/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0=
1057-
knative.dev/eventing v0.35.1-0.20230125080738-1f9f4d37aa56 h1:aBxfcRszMz6Ey6IgNVrEeDrkhApAeV8TV09qq95JtU4=
1058-
knative.dev/eventing v0.35.1-0.20230125080738-1f9f4d37aa56/go.mod h1:Qka5Z6+LeMoHGL1QAznVdmq5LAu21b4F3rgxc2AMgRg=
1057+
knative.dev/eventing v0.36.0 h1:a7kamc2S+LcpNMDX3llnwZm+DqMcYSXgKIgJXdaQQSY=
1058+
knative.dev/eventing v0.36.0/go.mod h1:Qka5Z6+LeMoHGL1QAznVdmq5LAu21b4F3rgxc2AMgRg=
10591059
knative.dev/hack v0.0.0-20230113013652-c7cfcb062de9 h1:CDa7s9KspEZqPhk7cN68ZypRLuAvSgr+knoOaXSsrHk=
10601060
knative.dev/hack v0.0.0-20230113013652-c7cfcb062de9/go.mod h1:yk2OjGDsbEnQjfxdm0/HJKS2WqTLEFg/N6nUs6Rqx3Q=
10611061
knative.dev/pkg v0.0.0-20230117181655-247510c00e9d h1:pjKDcvHoMib8nRp56eISRmMj/pFMzJljnzvMvGCIReI=

vendor/knative.dev/eventing/pkg/apis/sources/v1/apiserver_types.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,11 @@ type ApiServerSourceSpec struct {
8080
// source. Defaults to default if not set.
8181
// +optional
8282
ServiceAccountName string `json:"serviceAccountName,omitempty"`
83+
84+
// NamespaceSelector is a label selector to capture the namespaces that
85+
// should be watched by the source.
86+
// +optional
87+
NamespaceSelector *metav1.LabelSelector `json:"namespaceSelector,omitempty"`
8388
}
8489

8590
// ApiServerSourceStatus defines the observed state of ApiServerSource
@@ -92,6 +97,9 @@ type ApiServerSourceStatus struct {
9297
// * SinkURI - the current active sink URI that has been configured for the
9398
// Source.
9499
duckv1.SourceStatus `json:",inline"`
100+
101+
// Namespaces show the namespaces currently watched by the ApiServerSource
102+
Namespaces []string `json:"namespaces"`
95103
}
96104

97105
// APIVersionKind is an APIVersion and Kind tuple.

vendor/knative.dev/eventing/pkg/apis/sources/v1/zz_generated.deepcopy.go

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/knative.dev/eventing/pkg/reconciler/testing/v1/apiserversouce.go

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ func WithApiServerSourceSufficientPermissions(s *v1.ApiServerSource) {
111111
}
112112

113113
func WithApiServerSourceNoSufficientPermissions(s *v1.ApiServerSource) {
114-
s.Status.MarkNoSufficientPermissions("", `User system:serviceaccount:testnamespace:default cannot get, list, watch resource "namespaces" in API group ""`)
114+
s.Status.MarkNoSufficientPermissions("", `User system:serviceaccount:testnamespace:default cannot get, list, watch resource "namespaces" in API group "" in Namespace "testnamespace"`)
115115
}
116116

117117
func WithApiServerSourceDeleted(c *v1.ApiServerSource) {
@@ -136,3 +136,15 @@ func WithApiServerSourceObjectMetaGeneration(generation int64) ApiServerSourceOp
136136
c.ObjectMeta.Generation = generation
137137
}
138138
}
139+
140+
func WithApiServerSourceNamespaceSelector(nsSelector metav1.LabelSelector) ApiServerSourceOption {
141+
return func(c *v1.ApiServerSource) {
142+
c.Spec.NamespaceSelector = &nsSelector
143+
}
144+
}
145+
146+
func WithApiServerSourceStatusNamespaces(namespaces []string) ApiServerSourceOption {
147+
return func(c *v1.ApiServerSource) {
148+
c.Status.Namespaces = namespaces
149+
}
150+
}

vendor/knative.dev/eventing/pkg/reconciler/testing/v1/subscription.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,12 @@ func MarkNotAddedToChannel(reason, msg string) SubscriptionOption {
250250
}
251251
}
252252

253+
func MarkChannelFailed(reason, msg string) SubscriptionOption {
254+
return func(s *v1.Subscription) {
255+
s.Status.MarkChannelFailed(reason, msg)
256+
}
257+
}
258+
253259
func MarkReferencesResolved(s *v1.Subscription) {
254260
s.Status.MarkReferencesResolved()
255261
}

vendor/modules.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1221,7 +1221,7 @@ k8s.io/utils/net
12211221
k8s.io/utils/pointer
12221222
k8s.io/utils/strings/slices
12231223
k8s.io/utils/trace
1224-
# knative.dev/eventing v0.35.1-0.20230125080738-1f9f4d37aa56
1224+
# knative.dev/eventing v0.36.0
12251225
## explicit; go 1.18
12261226
knative.dev/eventing/pkg/adapter/v2
12271227
knative.dev/eventing/pkg/adapter/v2/util/crstatusevent

0 commit comments

Comments
 (0)