include all VMs when projects selected not just for admins - #7667
Conversation
|
@blueorangutan package |
|
@DaanHoogland a [SF] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
Codecov Report
@@ Coverage Diff @@
## 4.18 #7667 +/- ##
=========================================
Coverage 13.02% 13.02%
- Complexity 9030 9031 +1
=========================================
Files 2720 2720
Lines 257001 257001
Branches 40083 40083
=========================================
+ Hits 33463 33465 +2
+ Misses 219337 219334 -3
- Partials 4201 4202 +1
... and 1 file with indirect coverage changes 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
|
Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 6293 |
|
@blueorangutan test keepEnv |
|
@DaanHoogland a [SF] Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests |
|
[SF] Trillian test result (tid-6798)
|
| } | ||
| } | ||
| if (listAll) { | ||
| domainIdRecursiveListProject.third(ListProjectResourcesCriteria.ListAllIncludingProjectResources); |
There was a problem hiding this comment.
LGTM, should we worry if there could be negative consequences? (I'm asking to understand why this case was previously suported for admin only).
yadvr
left a comment
There was a problem hiding this comment.
Code LGTM, the listAll check should certainly work for all users but I'm not sure about any side-effects. Any manual QA/review would be great (as different user types/roles - both account and project roles).
|
@blueorangutan package |
|
@kiranchavala a [SF] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
|
Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 6515 |
There was a problem hiding this comment.
During Manual testing, I was unable to view the VMs and from my project's vm
Steps followed
1. Create a normal user role account under root domain
2. Login with the normal user account
3. Create a project
4. Change the view to project
5. Deploy a vm
6. Change the view back to normal
7. Deploy a vm
unable to view the 2 vm in normal view
I see what you mean @kiranchavala . this fix is API only (so far) I will look ate the UI as well. |
8841145 to
c8e2f3d
Compare
2becf79 to
9a804ee
Compare
|
@blueorangutan package |
|
@DaanHoogland a [SF] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
|
@kiranchavala , I tested this with the API. It should work as expected now. Sorry for the extra work. |
|
Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 6607 |
|
@blueorangutan test |
|
@DaanHoogland a [SF] Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests |
@DaanHoogland is the fix only for API or is UI also included ? |
The issue is API only, I checked the UI and it works without changes |
kiranchavala
left a comment
There was a problem hiding this comment.
The api calls are working fine but the in the UI (default view) , I am not able to view the vm's which belonging to a project view
list virtualmachines listall=true projectid=-1 filter=name
list virtualmachinesmetrics listall=true projectid=-1 filter=name
I just tested again and it works. Can you expand on your test procedure? |
|
Please find the steps that i followed
|
Its working fine forgot to toggle the projects |





Description
This PR makes so that when
project=-1andlistall=true,listVMsMetricsCmdreturns all VMs for the user, the same as for admin.Fixes: #7642
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Bug Severity
Screenshots (if appropriate):
How Has This Been Tested?