Skip to content

Commit f2b37a4

Browse files
committed
Unify column names and add missing age column
Signed-off-by: RainbowMango <qdurenhongcai@gmail.com>
1 parent c4a81bf commit f2b37a4

13 files changed

+42
-36
lines changed

charts/karmada-operator/crds/operator.karmada.io_karmadas.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ spec:
1818
versions:
1919
- additionalPrinterColumns:
2020
- jsonPath: .status.conditions[?(@.type=="Ready")].status
21-
name: Ready
21+
name: READY
2222
type: string
2323
- jsonPath: .metadata.creationTimestamp
24-
name: Age
24+
name: AGE
2525
type: date
2626
name: v1alpha1
2727
schema:

charts/karmada/_crds/bases/config/config.karmada.io_resourceinterpretercustomizations.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,13 @@ spec:
2121
- additionalPrinterColumns:
2222
- jsonPath: .spec.target.apiVersion
2323
name: TARGET-API-VERSION
24-
priority: 1
2524
type: string
2625
- jsonPath: .spec.target.kind
2726
name: TARGET-KIND
28-
priority: 1
2927
type: string
28+
- jsonPath: .metadata.creationTimestamp
29+
name: AGE
30+
type: date
3031
name: v1alpha1
3132
schema:
3233
openAPIV3Schema:

charts/karmada/_crds/bases/policy/policy.karmada.io_clusterpropagationpolicies.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,13 @@ spec:
2121
- additionalPrinterColumns:
2222
- jsonPath: .spec.conflictResolution
2323
name: CONFLICT-RESOLUTION
24-
priority: 1
2524
type: string
2625
- jsonPath: .spec.priority
2726
name: PRIORITY
28-
priority: 1
2927
type: string
28+
- jsonPath: .metadata.creationTimestamp
29+
name: AGE
30+
type: date
3031
name: v1alpha1
3132
schema:
3233
openAPIV3Schema:

charts/karmada/_crds/bases/policy/policy.karmada.io_propagationpolicies.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,13 @@ spec:
2121
- additionalPrinterColumns:
2222
- jsonPath: .spec.conflictResolution
2323
name: CONFLICT-RESOLUTION
24-
priority: 1
2524
type: string
2625
- jsonPath: .spec.priority
2726
name: PRIORITY
28-
priority: 1
2927
type: string
28+
- jsonPath: .metadata.creationTimestamp
29+
name: AGE
30+
type: date
3031
name: v1alpha1
3132
schema:
3233
openAPIV3Schema:

charts/karmada/_crds/bases/work/work.karmada.io_clusterresourcebindings.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -222,13 +222,13 @@ spec:
222222
status: {}
223223
- additionalPrinterColumns:
224224
- jsonPath: .status.conditions[?(@.type=="Scheduled")].status
225-
name: Scheduled
225+
name: SCHEDULED
226226
type: string
227227
- jsonPath: .status.conditions[?(@.type=="FullyApplied")].status
228-
name: FullyApplied
228+
name: FULLYAPPLIED
229229
type: string
230230
- jsonPath: .metadata.creationTimestamp
231-
name: Age
231+
name: AGE
232232
type: date
233233
name: v1alpha2
234234
schema:

charts/karmada/_crds/bases/work/work.karmada.io_resourcebindings.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -222,13 +222,13 @@ spec:
222222
status: {}
223223
- additionalPrinterColumns:
224224
- jsonPath: .status.conditions[?(@.type=="Scheduled")].status
225-
name: Scheduled
225+
name: SCHEDULED
226226
type: string
227227
- jsonPath: .status.conditions[?(@.type=="FullyApplied")].status
228-
name: FullyApplied
228+
name: FULLYAPPLIED
229229
type: string
230230
- jsonPath: .metadata.creationTimestamp
231-
name: Age
231+
name: AGE
232232
type: date
233233
name: v1alpha2
234234
schema:

charts/karmada/_crds/bases/work/work.karmada.io_works.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,13 @@ spec:
2020
versions:
2121
- additionalPrinterColumns:
2222
- jsonPath: .spec.workload.manifests[*].kind
23-
name: Workload-Kind
23+
name: WORKLOAD-KIND
2424
type: string
2525
- jsonPath: .status.conditions[?(@.type=="Applied")].status
26-
name: Applied
26+
name: APPLIED
2727
type: string
2828
- jsonPath: .metadata.creationTimestamp
29-
name: Age
29+
name: AGE
3030
type: date
3131
name: v1alpha1
3232
schema:

operator/config/crds/operator.karmada.io_karmadas.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ spec:
1818
versions:
1919
- additionalPrinterColumns:
2020
- jsonPath: .status.conditions[?(@.type=="Ready")].status
21-
name: Ready
21+
name: READY
2222
type: string
2323
- jsonPath: .metadata.creationTimestamp
24-
name: Age
24+
name: AGE
2525
type: date
2626
name: v1alpha1
2727
schema:

operator/pkg/apis/operator/v1alpha1/type.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ import (
2525
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
2626
// +kubebuilder:subresource:status
2727
// +kubebuilder:resource:path=karmadas,scope=Namespaced,categories={karmada-io}
28-
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="Ready")].status`,name="Ready",type=string
29-
// +kubebuilder:printcolumn:JSONPath=`.metadata.creationTimestamp`,name="Age",type=date
28+
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="Ready")].status`,name="READY",type=string
29+
// +kubebuilder:printcolumn:JSONPath=`.metadata.creationTimestamp`,name="AGE",type=date
3030

3131
// Karmada enables declarative installation of karmada.
3232
type Karmada struct {

pkg/apis/config/v1alpha1/resourceinterpretercustomization_types.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,9 @@ const (
3636
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
3737
// +kubebuilder:resource:path=resourceinterpretercustomizations,scope="Cluster",shortName=ric,categories={karmada-io}
3838
// +kubebuilder:storageversion
39-
// +kubebuilder:printcolumn:JSONPath=`.spec.target.apiVersion`,name="TARGET-API-VERSION",type=string,priority=1
40-
// +kubebuilder:printcolumn:JSONPath=`.spec.target.kind`,name="TARGET-KIND",type=string,priority=1
39+
// +kubebuilder:printcolumn:JSONPath=`.spec.target.apiVersion`,name="TARGET-API-VERSION",type=string
40+
// +kubebuilder:printcolumn:JSONPath=`.spec.target.kind`,name="TARGET-KIND",type=string
41+
// +kubebuilder:printcolumn:JSONPath=`.metadata.creationTimestamp`,name="AGE",type=date
4142

4243
// ResourceInterpreterCustomization describes the configuration of a specific
4344
// resource for Karmada to get the structure.

pkg/apis/policy/v1alpha1/propagation_types.go

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,9 @@ const (
4444
// +genclient
4545
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
4646
// +kubebuilder:resource:path=propagationpolicies,scope=Namespaced,shortName=pp,categories={karmada-io}
47-
// +kubebuilder:printcolumn:JSONPath=`.spec.conflictResolution`,name="CONFLICT-RESOLUTION",type=string,priority=1
48-
// +kubebuilder:printcolumn:JSONPath=`.spec.priority`,name="PRIORITY",type=string,priority=1
47+
// +kubebuilder:printcolumn:JSONPath=`.spec.conflictResolution`,name="CONFLICT-RESOLUTION",type=string
48+
// +kubebuilder:printcolumn:JSONPath=`.spec.priority`,name="PRIORITY",type=string
49+
// +kubebuilder:printcolumn:JSONPath=`.metadata.creationTimestamp`,name="AGE",type=date
4950

5051
// PropagationPolicy represents the policy that propagates a group of resources to one or more clusters.
5152
type PropagationPolicy struct {
@@ -564,8 +565,9 @@ type PropagationPolicyList struct {
564565
// +genclient:nonNamespaced
565566
// +kubebuilder:resource:path=clusterpropagationpolicies,scope="Cluster",shortName=cpp,categories={karmada-io}
566567
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
567-
// +kubebuilder:printcolumn:JSONPath=`.spec.conflictResolution`,name="CONFLICT-RESOLUTION",type=string,priority=1
568-
// +kubebuilder:printcolumn:JSONPath=`.spec.priority`,name="PRIORITY",type=string,priority=1
568+
// +kubebuilder:printcolumn:JSONPath=`.spec.conflictResolution`,name="CONFLICT-RESOLUTION",type=string
569+
// +kubebuilder:printcolumn:JSONPath=`.spec.priority`,name="PRIORITY",type=string
570+
// +kubebuilder:printcolumn:JSONPath=`.metadata.creationTimestamp`,name="AGE",type=date
569571

570572
// ClusterPropagationPolicy represents the cluster-wide policy that propagates a group of resources to one or more clusters.
571573
// Different with PropagationPolicy that could only propagate resources in its own namespace, ClusterPropagationPolicy

pkg/apis/work/v1alpha1/work_types.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ const (
3636
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
3737
// +kubebuilder:subresource:status
3838
// +kubebuilder:resource:path=works,scope=Namespaced,shortName=wk,categories={karmada-io}
39-
// +kubebuilder:printcolumn:JSONPath=`.spec.workload.manifests[*].kind`,name="Workload-Kind",type=string
40-
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="Applied")].status`,name="Applied",type=string
41-
// +kubebuilder:printcolumn:JSONPath=`.metadata.creationTimestamp`,name="Age",type=date
39+
// +kubebuilder:printcolumn:JSONPath=`.spec.workload.manifests[*].kind`,name="WORKLOAD-KIND",type=string
40+
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="Applied")].status`,name="APPLIED",type=string
41+
// +kubebuilder:printcolumn:JSONPath=`.metadata.creationTimestamp`,name="AGE",type=date
4242

4343
// Work defines a list of resources to be deployed on the member cluster.
4444
type Work struct {

pkg/apis/work/v1alpha2/binding_types.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,9 @@ const (
5050
// +kubebuilder:subresource:status
5151
// +kubebuilder:resource:path=resourcebindings,scope=Namespaced,shortName=rb,categories={karmada-io}
5252
// +kubebuilder:storageversion
53-
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="Scheduled")].status`,name="Scheduled",type=string
54-
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="FullyApplied")].status`,name="FullyApplied",type=string
55-
// +kubebuilder:printcolumn:JSONPath=`.metadata.creationTimestamp`,name="Age",type=date
53+
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="Scheduled")].status`,name="SCHEDULED",type=string
54+
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="FullyApplied")].status`,name="FULLYAPPLIED",type=string
55+
// +kubebuilder:printcolumn:JSONPath=`.metadata.creationTimestamp`,name="AGE",type=date
5656

5757
// ResourceBinding represents a binding of a kubernetes resource with a propagation policy.
5858
type ResourceBinding struct {
@@ -409,9 +409,9 @@ const (
409409
// +kubebuilder:resource:path=clusterresourcebindings,scope="Cluster",shortName=crb,categories={karmada-io}
410410
// +kubebuilder:subresource:status
411411
// +kubebuilder:storageversion
412-
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="Scheduled")].status`,name="Scheduled",type=string
413-
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="FullyApplied")].status`,name="FullyApplied",type=string
414-
// +kubebuilder:printcolumn:JSONPath=`.metadata.creationTimestamp`,name="Age",type=date
412+
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="Scheduled")].status`,name="SCHEDULED",type=string
413+
// +kubebuilder:printcolumn:JSONPath=`.status.conditions[?(@.type=="FullyApplied")].status`,name="FULLYAPPLIED",type=string
414+
// +kubebuilder:printcolumn:JSONPath=`.metadata.creationTimestamp`,name="AGE",type=date
415415

416416
// ClusterResourceBinding represents a binding of a kubernetes resource with a ClusterPropagationPolicy.
417417
type ClusterResourceBinding struct {

0 commit comments

Comments
 (0)