Skip to content

Commit

Permalink
Remove deprecated v1alpha1 Tier CRD
Browse files Browse the repository at this point in the history
Signed-off-by: Lan Luo <luola@vmware.com>
  • Loading branch information
luolanzone committed Mar 28, 2024
1 parent ba63acb commit 220920c
Show file tree
Hide file tree
Showing 16 changed files with 8 additions and 607 deletions.
26 changes: 0 additions & 26 deletions build/charts/antrea/crds/tier.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,32 +7,6 @@ metadata:
spec:
group: crd.antrea.io
versions:
- name: v1alpha1
served: true
storage: false
additionalPrinterColumns:
- name: Priority
type: integer
description: The Priority of this Tier relative to other Tiers.
jsonPath: .spec.priority
- name: Age
type: date
jsonPath: .metadata.creationTimestamp
schema:
openAPIV3Schema:
type: object
properties:
spec:
required:
- priority
type: object
properties:
priority:
type: integer
minimum: 0
maximum: 255
description:
type: string
- name: v1beta1
served: true
storage: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ webhooks:
rules:
- operations: ["CREATE", "UPDATE", "DELETE"]
apiGroups: ["crd.antrea.io"]
apiVersions: ["v1alpha1", "v1beta1"]
apiVersions: ["v1beta1"]
resources: ["tiers"]
scope: "Cluster"
admissionReviewVersions: ["v1", "v1beta1"]
Expand Down
2 changes: 1 addition & 1 deletion docs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ These are the CRDs currently available in `crd.antrea.io`.
| `NetworkPolicy` | v1alpha1 | v1.0.0 | v1.13.0 | N/A |
| `NetworkPolicy` | v1beta1 | v1.13.0 | N/A | N/A |
| `SupportBundleCollection` | v1alpha1 | v1.10.0 | N/A | N/A |
| `Tier` | v1alpha1 | v1.0.0 | v1.13.0 | v2.0.0 |
| `Tier` | v1beta1 | v1.13.0 | N/A | N/A |
| `Traceflow` | v1alpha1 | v1.0.0 | v1.13.0 | N/A |
| `Traceflow` | v1beta1 | v1.13.0 | N/A | N/A |
Expand Down Expand Up @@ -81,3 +80,4 @@ These are the API group versions which are currently available when using Antrea
| CRD | CRD version | Introduced in | Deprecated in | Removed in |
|---|---|---|---|---|
| `ClusterGroup` | v1alpha2 | v1.0.0 | v1.1.0 | v2.0.0 |
| `Tier` | v1alpha1 | v1.0.0 | v1.13.0 | v2.0.0 |
2 changes: 0 additions & 2 deletions pkg/apis/crd/v1alpha1/register.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,6 @@ func addKnownTypes(scheme *runtime.Scheme) error {
&NetworkPolicyList{},
&ClusterNetworkPolicy{},
&ClusterNetworkPolicyList{},
&Tier{},
&TierList{},
&ExternalNode{},
&ExternalNodeList{},
&SupportBundleCollection{},
Expand Down
33 changes: 0 additions & 33 deletions pkg/apis/crd/v1alpha1/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -676,39 +676,6 @@ type ClusterNetworkPolicyList struct {
Items []ClusterNetworkPolicy `json:"items"`
}

// +genclient
// +genclient:nonNamespaced
// +genclient:noStatus
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

type Tier struct {
metav1.TypeMeta `json:",inline"`
// Standard metadata of the object.
metav1.ObjectMeta `json:"metadata,omitempty"`

// Specification of the desired behavior of Tier.
Spec TierSpec `json:"spec"`
}

// TierSpec defines the desired state for Tier.
type TierSpec struct {
// Priority specfies the order of the Tier relative to other Tiers.
Priority int32 `json:"priority"`
// Description is an optional field to add more information regarding
// the purpose of this Tier.
Description string `json:"description,omitempty"`
}

// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

type TierList struct {
metav1.TypeMeta `json:",inline"`
// +optional
metav1.ListMeta `json:"metadata,omitempty"`

Items []Tier `json:"items"`
}

// NamespacedName refers to a Namespace scoped resource.
// All fields must be used together.
type NamespacedName struct {
Expand Down
78 changes: 1 addition & 77 deletions pkg/apis/crd/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

119 changes: 0 additions & 119 deletions pkg/client/clientset/versioned/typed/crd/v1alpha1/fake/fake_tier.go

This file was deleted.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 220920c

Please sign in to comment.