-
Notifications
You must be signed in to change notification settings - Fork 363
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add columns of kubectl outputs for Multi-cluster types #3923
Conversation
bed4d6a
to
06ec507
Compare
Codecov Report
@@ Coverage Diff @@
## main #3923 +/- ##
==========================================
- Coverage 64.16% 64.07% -0.09%
==========================================
Files 293 293
Lines 43223 43223
==========================================
- Hits 27735 27697 -38
- Misses 13256 13294 +38
Partials 2232 2232
Flags with carried forward coverage won't be shown. Click here to find out more.
|
@@ -31,14 +31,16 @@ const ( | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@luolanzone : I think we should use "internal" and "external" to be consistent with Node IP types. Could we add "internal" / "external" and meanwhile keep supporting "private" / "public“?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure, I will refine it to support both.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just checked the code, I feel it would be better to include the change in this PR. I believe you just need to add two more const here: https://github.com/antrea-io/antrea/blob/main/multicluster/apis/multicluster/v1alpha1/multiclusterconfig_types.go#L27-L30.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to change the backend handling (decide which IP to use based on the option) right.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh, yes, you are right, you can leave it. I will update it later.
06ec507
to
171a6fc
Compare
@luolanzone : I would also update the user guide to use the table format for "kubectl get" outputs. So, either I merge the PR first, and you create a new one to update the docs; or you apply the new yamls to your env, and give me the example outputs for me to update the docs together. |
@@ -30,7 +30,9 @@ const ( | |||
// +genclient | |||
//+kubebuilder:object:root=true | |||
|
|||
// ClusterClaim is the Schema for the clusterclaims API | |||
// +kubebuilder:printcolumn:name="Value",type=string,JSONPath=`.value`,description="Value of the ClusterClaim" | |||
// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp" | |
// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=`.metadata.creationTimestamp` |
looks like both `` and ""
works, we may keep the format consistent.
There are a few other comments need to be updated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, updated.
// ClusterSet is the Schema for the clustersets API. | ||
// +kubebuilder:printcolumn:name="Leader Cluster Namespace",type=string,JSONPath=`.spec.namespace`,description="The leader cluster Namespace for the ClusterSet" | ||
// +kubebuilder:printcolumn:name="Total Clusters",type=string,JSONPath=`.status.totalClusters`,description="Total number of clusters in the ClusterSet" | ||
// +kubebuilder:printcolumn:name="Ready Clusters",type=string,JSONPath=`.status.readyClusters`,description="Number of ready clusters in the ClusterSet" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// +kubebuilder:printcolumn:name="Ready Clusters",type=string,JSONPath=`.status.readyClusters`,description="Number of ready clusters in the ClusterSet" | |
// +kubebuilder:printcolumn:name="Ready Member Clusters",type=string,JSONPath=`.status.readyClusters`,description="Number of ready member clusters in the ClusterSet" |
Leader cluster is not included in the ready clusters, so better to add Member
here. Otherwise user might be confused to see inconsistent data between totalClusters
and readyClusters
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel we should change totalClusters to include only member clusters, as we support only a single leader cluster. What you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds reasonable, I can update totalClusters and GatewayIPPrecedence after you merge this.
/test-multicluster-dataplane-e2e |
Signed-off-by: Jianjun Shen <shenj@vmware.com>
171a6fc
to
5514464
Compare
/test-multicluster-e2e |
2 similar comments
/test-multicluster-e2e |
/test-multicluster-e2e |
Sure, I think I can update docs when I refine totalClusters and GatewayIPPrecedence after you merge this PR, is this OK? |
Sounds good. |
/skip-all |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Signed-off-by: Jianjun Shen shenj@vmware.com