Skip to content

Commit 81c25cf

Browse files
authored
Merge pull request #1157 from fluxcd/remove-v1beta1-api
Remove deprecated APIs in group `notification.toolkit.fluxcd.io/v1beta1`
2 parents 4d1c503 + 660e7d2 commit 81c25cf

File tree

7 files changed

+6
-593
lines changed

7 files changed

+6
-593
lines changed

api/v1beta1/alert_types.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -68,11 +68,7 @@ type AlertStatus struct {
6868

6969
// +genclient
7070
// +kubebuilder:object:root=true
71-
// +kubebuilder:subresource:status
72-
// +kubebuilder:deprecatedversion:warning="v1beta1 Alert is deprecated, upgrade to v1beta3"
73-
// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp",description=""
74-
// +kubebuilder:printcolumn:name="Ready",type="string",JSONPath=".status.conditions[?(@.type==\"Ready\")].status",description=""
75-
// +kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.conditions[?(@.type==\"Ready\")].message",description=""
71+
// +kubebuilder:skipversion
7672

7773
// Alert is the Schema for the alerts API
7874
type Alert struct {

api/v1beta1/doc.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@ limitations under the License.
1515
*/
1616

1717
// Package v1beta1 contains API Schema definitions for the notification v1beta1 API group
18+
//
19+
// Deprecated: v1beta1 is no longer supported, use v1 and v1beta3 instead.
20+
//
1821
// +kubebuilder:object:generate=true
1922
// +groupName=notification.toolkit.fluxcd.io
2023
package v1beta1

api/v1beta1/provider_types.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -111,11 +111,7 @@ type ProviderStatus struct {
111111

112112
// +genclient
113113
// +kubebuilder:object:root=true
114-
// +kubebuilder:subresource:status
115-
// +kubebuilder:deprecatedversion:warning="v1beta1 Provider is deprecated, upgrade to v1beta3"
116-
// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp",description=""
117-
// +kubebuilder:printcolumn:name="Ready",type="string",JSONPath=".status.conditions[?(@.type==\"Ready\")].status",description=""
118-
// +kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.conditions[?(@.type==\"Ready\")].message",description=""
114+
// +kubebuilder:skipversion
119115

120116
// Provider is the Schema for the providers API
121117
type Provider struct {

api/v1beta1/receiver_types.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,11 +98,7 @@ func (in *Receiver) SetConditions(conditions []metav1.Condition) {
9898

9999
// +genclient
100100
// +kubebuilder:object:root=true
101-
// +kubebuilder:subresource:status
102-
// +kubebuilder:deprecatedversion:warning="v1beta1 Receiver is deprecated, upgrade to v1"
103-
// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp",description=""
104-
// +kubebuilder:printcolumn:name="Ready",type="string",JSONPath=".status.conditions[?(@.type==\"Ready\")].status",description=""
105-
// +kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.conditions[?(@.type==\"Ready\")].message",description=""
101+
// +kubebuilder:skipversion
106102

107103
// Receiver is the Schema for the receivers API
108104
type Receiver struct {

config/crd/bases/notification.toolkit.fluxcd.io_alerts.yaml

Lines changed: 0 additions & 192 deletions
Original file line numberDiff line numberDiff line change
@@ -14,198 +14,6 @@ spec:
1414
singular: alert
1515
scope: Namespaced
1616
versions:
17-
- additionalPrinterColumns:
18-
- jsonPath: .metadata.creationTimestamp
19-
name: Age
20-
type: date
21-
- jsonPath: .status.conditions[?(@.type=="Ready")].status
22-
name: Ready
23-
type: string
24-
- jsonPath: .status.conditions[?(@.type=="Ready")].message
25-
name: Status
26-
type: string
27-
deprecated: true
28-
deprecationWarning: v1beta1 Alert is deprecated, upgrade to v1beta3
29-
name: v1beta1
30-
schema:
31-
openAPIV3Schema:
32-
description: Alert is the Schema for the alerts API
33-
properties:
34-
apiVersion:
35-
description: |-
36-
APIVersion defines the versioned schema of this representation of an object.
37-
Servers should convert recognized schemas to the latest internal value, and
38-
may reject unrecognized values.
39-
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
40-
type: string
41-
kind:
42-
description: |-
43-
Kind is a string value representing the REST resource this object represents.
44-
Servers may infer this from the endpoint the client submits requests to.
45-
Cannot be updated.
46-
In CamelCase.
47-
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
48-
type: string
49-
metadata:
50-
type: object
51-
spec:
52-
description: AlertSpec defines an alerting rule for events involving a
53-
list of objects
54-
properties:
55-
eventSeverity:
56-
default: info
57-
description: |-
58-
Filter events based on severity, defaults to ('info').
59-
If set to 'info' no events will be filtered.
60-
enum:
61-
- info
62-
- error
63-
type: string
64-
eventSources:
65-
description: Filter events based on the involved objects.
66-
items:
67-
description: |-
68-
CrossNamespaceObjectReference contains enough information to let you locate the
69-
typed referenced object at cluster level
70-
properties:
71-
apiVersion:
72-
description: API version of the referent
73-
type: string
74-
kind:
75-
description: Kind of the referent
76-
enum:
77-
- Bucket
78-
- GitRepository
79-
- Kustomization
80-
- HelmRelease
81-
- HelmChart
82-
- HelmRepository
83-
- ImageRepository
84-
- ImagePolicy
85-
- ImageUpdateAutomation
86-
- OCIRepository
87-
type: string
88-
matchLabels:
89-
additionalProperties:
90-
type: string
91-
description: |-
92-
MatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
93-
map is equivalent to an element of matchExpressions, whose key field is "key", the
94-
operator is "In", and the values array contains only "value". The requirements are ANDed.
95-
type: object
96-
name:
97-
description: Name of the referent
98-
maxLength: 53
99-
minLength: 1
100-
type: string
101-
namespace:
102-
description: Namespace of the referent
103-
maxLength: 53
104-
minLength: 1
105-
type: string
106-
required:
107-
- kind
108-
- name
109-
type: object
110-
type: array
111-
exclusionList:
112-
description: A list of Golang regular expressions to be used for excluding
113-
messages.
114-
items:
115-
type: string
116-
type: array
117-
providerRef:
118-
description: Send events using this provider.
119-
properties:
120-
name:
121-
description: Name of the referent.
122-
type: string
123-
required:
124-
- name
125-
type: object
126-
summary:
127-
description: Short description of the impact and affected cluster.
128-
type: string
129-
suspend:
130-
description: |-
131-
This flag tells the controller to suspend subsequent events dispatching.
132-
Defaults to false.
133-
type: boolean
134-
required:
135-
- eventSources
136-
- providerRef
137-
type: object
138-
status:
139-
default:
140-
observedGeneration: -1
141-
description: AlertStatus defines the observed state of Alert
142-
properties:
143-
conditions:
144-
items:
145-
description: Condition contains details for one aspect of the current
146-
state of this API Resource.
147-
properties:
148-
lastTransitionTime:
149-
description: |-
150-
lastTransitionTime is the last time the condition transitioned from one status to another.
151-
This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.
152-
format: date-time
153-
type: string
154-
message:
155-
description: |-
156-
message is a human readable message indicating details about the transition.
157-
This may be an empty string.
158-
maxLength: 32768
159-
type: string
160-
observedGeneration:
161-
description: |-
162-
observedGeneration represents the .metadata.generation that the condition was set based upon.
163-
For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date
164-
with respect to the current state of the instance.
165-
format: int64
166-
minimum: 0
167-
type: integer
168-
reason:
169-
description: |-
170-
reason contains a programmatic identifier indicating the reason for the condition's last transition.
171-
Producers of specific condition types may define expected values and meanings for this field,
172-
and whether the values are considered a guaranteed API.
173-
The value should be a CamelCase string.
174-
This field may not be empty.
175-
maxLength: 1024
176-
minLength: 1
177-
pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
178-
type: string
179-
status:
180-
description: status of the condition, one of True, False, Unknown.
181-
enum:
182-
- "True"
183-
- "False"
184-
- Unknown
185-
type: string
186-
type:
187-
description: type of condition in CamelCase or in foo.example.com/CamelCase.
188-
maxLength: 316
189-
pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
190-
type: string
191-
required:
192-
- lastTransitionTime
193-
- message
194-
- reason
195-
- status
196-
- type
197-
type: object
198-
type: array
199-
observedGeneration:
200-
description: ObservedGeneration is the last observed generation.
201-
format: int64
202-
type: integer
203-
type: object
204-
type: object
205-
served: true
206-
storage: false
207-
subresources:
208-
status: {}
20917
- additionalPrinterColumns:
21018
- jsonPath: .metadata.creationTimestamp
21119
name: Age

0 commit comments

Comments
 (0)