Bug 2037625
Summary: | AppliedClusterResourceQuotas can not be shown on project overview | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | OpenShift Container Platform | Reporter: | Yadan Pei <yapei> | ||||||||
Component: | Management Console | Assignee: | Yadan Pei <yapei> | ||||||||
Status: | CLOSED ERRATA | QA Contact: | Yadan Pei <yapei> | ||||||||
Severity: | medium | Docs Contact: | |||||||||
Priority: | unspecified | ||||||||||
Version: | 4.10 | CC: | aos-bugs, jhadvig, sdharma, yapei | ||||||||
Target Milestone: | --- | ||||||||||
Target Release: | 4.11.0 | ||||||||||
Hardware: | Unspecified | ||||||||||
OS: | Unspecified | ||||||||||
Whiteboard: | |||||||||||
Fixed In Version: | Doc Type: | No Doc Update | |||||||||
Doc Text: | Story Points: | --- | |||||||||
Clone Of: | Environment: | ||||||||||
Last Closed: | 2022-08-10 10:41:16 UTC | Type: | Bug | ||||||||
Regression: | --- | Mount Type: | --- | ||||||||
Documentation: | --- | CRM: | |||||||||
Verified Versions: | Category: | --- | |||||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||||
Embargoed: | |||||||||||
Attachments: |
|
Description
Yadan Pei
2022-01-06 07:10:32 UTC
Created attachment 1849173 [details]
ResourceQuotas page show AppliedClusterResourceQuota
Hi @yapei - This is working as intended. I followed the existing behavior for the AppliedClusterResourceQuotas chart. The pre-ACRQ chart only displayed on the details page or project details page if there was data set for limits.cpu, requests.memory, limits.memory, etc. If you add those into your YAML, the chart will show up. Are you looking to have the behavior changed for all types of data using these charts (ResourceQuota, AppliedClusterResourceQuota, ClusterResourceQuota)? Is it consistent with https://github.com/openshift/console/pull/10137? I see the ACRQ chart is shown in project details page even no data set for limits.cpu, requests.memory, limits.memory, am I wrong? Hey Yadan - Sorry for the late reply on this; I've been in and out of the office. The lack of data in the charts refers to the fact that there are no resources under the quota that apply to the limit. The data only shows up if there are pods, etc. that are in the project. The charts themselves only show up if there is an actual limit set. If you try this YAML and create a project called ralpert, you can see that the charts will show up but will be blank unless you add a pod or similar with limits: apiVersion: quota.openshift.io/v1 kind: ClusterResourceQuota metadata: name: example spec: quota: hard: pods: 10 secrets: 10 requests.cpu: '1' requests.memory: 1Gi limits.cpu: '2' limits.memory: 2Gi selector: labels: matchLabels: 'kubernetes.io/metadata.name': ralpert Hey @yapei - Just following up on this. Are you looking to have the behavior changed for all types of data using these charts (ResourceQuota, AppliedClusterResourceQuota, ClusterResourceQuota)? Or just ACRQs. (It's shared code.) Thanks! (In reply to ralpert from comment #7) > Hey @yapei - Just following up on this. Are you looking to have > the behavior changed for all types of data using these charts > (ResourceQuota, AppliedClusterResourceQuota, ClusterResourceQuota)? Or just > ACRQs. (It's shared code.) Thanks! Sorry Rebecca, I thought I should already added comments but didn't. I tried the steps in comment 5, ACRQs are showing on project overview page when limits.cpu, requests.memory, limits.memory, etc values are set I think there's a miscommunication here - there is shared code for all the quota charts. I'm trying to figure out if you want to show the charts all the time for all the quotas or if you want to special case ACRQ charts so you don't need that data. Can you let me know how you want to proceed? Created attachment 1862482 [details]
normal user can view ACRQ
1. normal user has a project
$ oc login xxxx -u yapei -p redhat
$ oc new-project yapei-test
2. cluster admin creates clusterresourcequota and targets projects created by user 'yapei'
$ oc create clusterquota for-user --project-annotation-selector openshift.io/requester=yapei --hard pods=10 --hard secrets=20
W0106 14:12:06.237049 57071 shim_kubectl.go:63] Using non-groupfied API resources is deprecated and will be removed in a future release, update apiVersion to "quota.openshift.io/v1" for your resource
clusterresourcequota.quota.openshift.io/for-user created
3. normal user view appliedclusterresourcequota
$ oc get appliedclusterresourcequota
NAME LABELS SELECTOR ANNOTATIONS SELECTOR
for-user <none> map[openshift.io/requester:yapei2]
4. normal user view project overview at /k8s/cluster/projects/yapei2-project
5. cluster admin user view project overview /k8s/cluster/projects/yapei2-project
for 4 and 5, both normal user and cluster admin user can view ARCQ in project overview
verified on 4.11.0-0.nightly-2022-02-18-121223
ACRQ is always shown on project overview page Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (Important: OpenShift Container Platform 4.11.0 bug fix and security update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2022:5069 |