Skip to content
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

v1beta1 additionalPrinterColumns for tenant owner info #331

Closed
MaxFedotov opened this issue Jul 8, 2021 · 8 comments
Closed

v1beta1 additionalPrinterColumns for tenant owner info #331

MaxFedotov opened this issue Jul 8, 2021 · 8 comments
Assignees
Labels
blocked-needs-validation Issue need triage and validation needs-discussion No outline on the feature, discussion is welcome
Milestone

Comments

@MaxFedotov
Copy link
Collaborator

In v1alpha1 version of capsule, tenant can only have a single owner, so we added

// +kubebuilder:printcolumn:name="Owner name",type="string",JSONPath=".spec.owner.name",description="The assigned Tenant owner"
// +kubebuilder:printcolumn:name="Owner kind",type="string",JSONPath=".spec.owner.kind",description="The assigned Tenant owner kind"

to additionalPrinterColumns in crd spec.

But in v1beta1 it is possible to specify multiple owners for a tenant, and as additionalPrinterColumns doesn't support arrays (kubernetes/kubectl#517) we need to find a solution how to show user information about tenant owners (or may be we don't need to show it at all)

@bsctl @prometherion need your ideas :)

@MaxFedotov MaxFedotov added the blocked-needs-validation Issue need triage and validation label Jul 8, 2021
@prometherion prometherion added the needs-discussion No outline on the feature, discussion is welcome label Jul 8, 2021
@prometherion prometherion added this to the v0.1.0 milestone Jul 8, 2021
@prometherion
Copy link
Member

Since we're going for multiple owners, we could drop the support for the Owner columns, also because it's something out of our scope and a limitation of upstream Kubernetes project.

Let's wait @bsctl's feedback.

@bsctl
Copy link
Member

bsctl commented Jul 8, 2021

Removing the field from CRD breaks some UIs we built on top of Capsule, including the customer one.

What about to keep the field in CRD and populate it with only the first element of the array? Sounds ugly … but doesn’t break the customer’s UI.

@bsctl
Copy link
Member

bsctl commented Jul 15, 2021

@prometherion @MaxFedotov any idea how to solve this?

@prometherion
Copy link
Member

Removing the field from CRD breaks some UIs we built on top of Capsule, including the customer one.

We're not removing any field from the CRD, but rather we're talking about the additional printer column used by kubectl.

If any dashboard has been implemented on top of Capsule, there are no breaking changes until it uses the v1alpha endpoint rather than v1beta1, although the upgrade should be planned since the new version is going to support tenant owners.

What about to keep the field in CRD and populate it with only the first element of the array?

For v1alpha it will be kept, but since v1beta implements multiple owners, we have to remove it.

@bsctl
Copy link
Member

bsctl commented Jul 15, 2021

@prometherion Thanks got it.

@bsctl
Copy link
Member

bsctl commented Jul 15, 2021

Noted already removed in master

$ kubectl get tnt
NAME   STATE    NAMESPACE QUOTA   NAMESPACE COUNT   NODE SELECTOR    AGE
gas    active   9                 0                 {"pool":"cmp"}   34m
gold   active   9                 0                 {"pool":"cmp"}   33m
oil    active   9                 0                 {"pool":"cmp"}   54m

going to close the issue?

@MaxFedotov
Copy link
Collaborator Author

@bsctl if you are ok with removing it - issue can be closed :)

@bsctl
Copy link
Member

bsctl commented Jul 15, 2021

It looks like no way, according to comments above :)

@bsctl bsctl closed this as completed Jul 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked-needs-validation Issue need triage and validation needs-discussion No outline on the feature, discussion is welcome
Projects
None yet
Development

No branches or pull requests

3 participants