Skip to content

Commit 2f294c7

Browse files
Deprecate v1alpha3 and v1alpha4 apiVersions
Signed-off-by: killianmuldoon <[email protected]>
1 parent 32cbee4 commit 2f294c7

29 files changed

+152
-42
lines changed

.golangci.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,11 @@ issues:
5757
- linters:
5858
- staticcheck
5959
text: "SA1019: failureDomain.AutoConfigure is deprecated"
60+
# Specific exclude rules for deprecated packages that are still part of the codebase. These
61+
# should be removed as the referenced deprecated packages are removed from the project.
62+
- linters:
63+
- staticcheck
64+
text: "SA1019: .* is deprecated: This package will be removed in one of the next releases."
6065
- path: "test/e2e/*"
6166
linters:
6267
- gosec

apis/v1alpha3/doc.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,6 @@ limitations under the License.
1818
// +kubebuilder:object:generate=true
1919
// +groupName=infrastructure.cluster.x-k8s.io
2020
// +k8s:conversion-gen=sigs.k8s.io/cluster-api-provider-vsphere/apis/v1beta1
21+
//
22+
// Deprecated: This package will be removed in one of the next releases.
2123
package v1alpha3

apis/v1alpha3/haproxyloadbalancer_types.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,11 +62,13 @@ type HAProxyLoadBalancerStatus struct {
6262
}
6363

6464
// +kubebuilder:object:root=true
65+
// +kubebuilder:deprecatedversion
6566
// +kubebuilder:resource:path=haproxyloadbalancers,scope=Namespaced
6667
// +kubebuilder:subresource:status
6768

6869
// HAProxyLoadBalancer is the Schema for the haproxyloadbalancers API
69-
// DEPRECATED: will be removed in v1alpha4
70+
//
71+
// Deprecated: This type will be removed in v1alpha4.
7072
type HAProxyLoadBalancer struct {
7173
metav1.TypeMeta `json:",inline"`
7274
metav1.ObjectMeta `json:"metadata,omitempty"`
@@ -78,6 +80,8 @@ type HAProxyLoadBalancer struct {
7880
// +kubebuilder:object:root=true
7981

8082
// HAProxyLoadBalancerList contains a list of HAProxyLoadBalancer
83+
//
84+
// Deprecated: This type will be removed in one of the next releases.
8185
type HAProxyLoadBalancerList struct {
8286
metav1.TypeMeta `json:",inline"`
8387
metav1.ListMeta `json:"metadata,omitempty"`

apis/v1alpha3/vspherecluster_types.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ type VSphereClusterStatus struct {
8484
}
8585

8686
// +kubebuilder:object:root=true
87+
// +kubebuilder:deprecatedversion
8788
// +kubebuilder:resource:path=vsphereclusters,scope=Namespaced,categories=cluster-api
8889
// +kubebuilder:subresource:status
8990
// +kubebuilder:printcolumn:name="Ready",type="string",JSONPath=".status.ready",description="Cluster infrastructure is ready for VSphereMachine"
@@ -92,6 +93,8 @@ type VSphereClusterStatus struct {
9293
// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp",description="Time duration since creation of Machine"
9394

9495
// VSphereCluster is the Schema for the vsphereclusters API
96+
//
97+
// Deprecated: This type will be removed in one of the next releases.
9598
type VSphereCluster struct {
9699
metav1.TypeMeta `json:",inline"`
97100
metav1.ObjectMeta `json:"metadata,omitempty"`
@@ -111,6 +114,8 @@ func (m *VSphereCluster) SetConditions(conditions clusterv1.Conditions) {
111114
// +kubebuilder:object:root=true
112115

113116
// VSphereClusterList contains a list of VSphereCluster
117+
//
118+
// Deprecated: This type will be removed in one of the next releases.
114119
type VSphereClusterList struct {
115120
metav1.TypeMeta `json:",inline"`
116121
metav1.ListMeta `json:"metadata,omitempty"`

apis/v1alpha3/vsphereclusteridentity_types.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,10 +79,13 @@ func (c *VSphereClusterIdentity) SetConditions(conditions clusterv1.Conditions)
7979
}
8080

8181
// +kubebuilder:object:root=true
82+
// +kubebuilder:deprecatedversion
8283
// +kubebuilder:resource:path=vsphereclusteridentities,scope=Cluster,categories=cluster-api
8384
// +kubebuilder:subresource:status
8485

8586
// VSphereClusterIdentity defines the account to be used for reconciling clusters
87+
//
88+
// Deprecated: This type will be removed in one of the next releases.
8689
type VSphereClusterIdentity struct {
8790
metav1.TypeMeta `json:",inline"`
8891
metav1.ObjectMeta `json:"metadata,omitempty"`
@@ -93,6 +96,8 @@ type VSphereClusterIdentity struct {
9396

9497
// +kubebuilder:object:root=true
9598
// VSphereClusterIdentityList contains a list of VSphereClusterIdentity
99+
//
100+
// Deprecated: This type will be removed in one of the next releases.
96101
type VSphereClusterIdentityList struct {
97102
metav1.TypeMeta `json:",inline"`
98103
metav1.ListMeta `json:"metadata,omitempty"`

apis/v1alpha3/vspheredeploymentzone_types.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,10 +78,13 @@ type VSphereDeploymentZoneStatus struct {
7878
}
7979

8080
// +kubebuilder:object:root=true
81+
// +kubebuilder:deprecatedversion
8182
// +kubebuilder:resource:path=vspheredeploymentzones,scope=Cluster,categories=cluster-api
8283
// +kubebuilder:subresource:status
8384

8485
// VSphereDeploymentZone is the Schema for the vspheredeploymentzones API
86+
//
87+
// Deprecated: This type will be removed in one of the next releases.
8588
type VSphereDeploymentZone struct {
8689
metav1.TypeMeta `json:",inline"`
8790
metav1.ObjectMeta `json:"metadata,omitempty"`
@@ -93,6 +96,8 @@ type VSphereDeploymentZone struct {
9396
// +kubebuilder:object:root=true
9497

9598
// VSphereDeploymentZoneList contains a list of VSphereDeploymentZone
99+
//
100+
// Deprecated: This type will be removed in one of the next releases.
96101
type VSphereDeploymentZoneList struct {
97102
metav1.TypeMeta `json:",inline"`
98103
metav1.ListMeta `json:"metadata,omitempty"`

apis/v1alpha3/vspherefailuredomain_types.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,9 +89,12 @@ type FailureDomainHosts struct {
8989
}
9090

9191
// +kubebuilder:object:root=true
92+
// +kubebuilder:deprecatedversion
9293
// +kubebuilder:resource:path=vspherefailuredomains,scope=Cluster,categories=cluster-api
9394

9495
// VSphereFailureDomain is the Schema for the vspherefailuredomains API
96+
//
97+
// Deprecated: This type will be removed in one of the next releases.
9598
type VSphereFailureDomain struct {
9699
metav1.TypeMeta `json:",inline"`
97100
metav1.ObjectMeta `json:"metadata,omitempty"`
@@ -102,6 +105,8 @@ type VSphereFailureDomain struct {
102105
// +kubebuilder:object:root=true
103106

104107
// VSphereFailureDomainList contains a list of VSphereFailureDomain
108+
//
109+
// Deprecated: This type will be removed in one of the next releases.
105110
type VSphereFailureDomainList struct {
106111
metav1.TypeMeta `json:",inline"`
107112
metav1.ListMeta `json:"metadata,omitempty"`

apis/v1alpha3/vspheremachine_types.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ type VSphereMachineStatus struct {
102102
}
103103

104104
// +kubebuilder:object:root=true
105+
// +kubebuilder:deprecatedversion
105106
// +kubebuilder:resource:path=vspheremachines,scope=Namespaced,categories=cluster-api
106107
// +kubebuilder:subresource:status
107108
// +kubebuilder:printcolumn:name="Cluster",type="string",JSONPath=".metadata.labels.cluster\\.x-k8s\\.io/cluster-name",description="Cluster to which this VSphereMachine belongs"
@@ -111,6 +112,8 @@ type VSphereMachineStatus struct {
111112
// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp",description="Time duration since creation of Machine"
112113

113114
// VSphereMachine is the Schema for the vspheremachines API
115+
//
116+
// Deprecated: This type will be removed in one of the next releases.
114117
type VSphereMachine struct {
115118
metav1.TypeMeta `json:",inline"`
116119
metav1.ObjectMeta `json:"metadata,omitempty"`
@@ -130,6 +133,8 @@ func (m *VSphereMachine) SetConditions(conditions clusterv1.Conditions) {
130133
// +kubebuilder:object:root=true
131134

132135
// VSphereMachineList contains a list of VSphereMachine
136+
//
137+
// Deprecated: This type will be removed in one of the next releases.
133138
type VSphereMachineList struct {
134139
metav1.TypeMeta `json:",inline"`
135140
metav1.ListMeta `json:"metadata,omitempty"`

apis/v1alpha3/vspheremachinetemplate_types.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,12 @@ type VSphereMachineTemplateSpec struct {
2727
}
2828

2929
// +kubebuilder:object:root=true
30+
// +kubebuilder:deprecatedversion
3031
// +kubebuilder:resource:path=vspheremachinetemplates,scope=Namespaced,categories=cluster-api
3132

3233
// VSphereMachineTemplate is the Schema for the vspheremachinetemplates API
34+
//
35+
// Deprecated: This type will be removed in one of the next releases.
3336
type VSphereMachineTemplate struct {
3437
metav1.TypeMeta `json:",inline"`
3538
metav1.ObjectMeta `json:"metadata,omitempty"`
@@ -40,6 +43,8 @@ type VSphereMachineTemplate struct {
4043
// +kubebuilder:object:root=true
4144

4245
// VSphereMachineTemplateList contains a list of VSphereMachineTemplate
46+
//
47+
// Deprecated: This type will be removed in one of the next releases.
4348
type VSphereMachineTemplateList struct {
4449
metav1.TypeMeta `json:",inline"`
4550
metav1.ListMeta `json:"metadata,omitempty"`

apis/v1alpha3/vspherevm_types.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,10 +126,13 @@ type VSphereVMStatus struct {
126126
}
127127

128128
// +kubebuilder:object:root=true
129+
// +kubebuilder:deprecatedversion
129130
// +kubebuilder:resource:path=vspherevms,scope=Namespaced,categories=cluster-api
130131
// +kubebuilder:subresource:status
131132

132133
// VSphereVM is the Schema for the vspherevms API
134+
//
135+
// Deprecated: This type will be removed in one of the next releases.
133136
type VSphereVM struct {
134137
metav1.TypeMeta `json:",inline"`
135138
metav1.ObjectMeta `json:"metadata,omitempty"`
@@ -149,6 +152,8 @@ func (m *VSphereVM) SetConditions(conditions clusterv1.Conditions) {
149152
// +kubebuilder:object:root=true
150153

151154
// VSphereVMList contains a list of VSphereVM
155+
//
156+
// Deprecated: This type will be removed in one of the next releases.
152157
type VSphereVMList struct {
153158
metav1.TypeMeta `json:",inline"`
154159
metav1.ListMeta `json:"metadata,omitempty"`

0 commit comments

Comments
 (0)