Horizon doesn't show complete flavor access list

Bug #1315479 reported by Dimitri Mazmanov
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Dashboard (Horizon)
Won't Fix
Undecided
Unassigned

Bug Description

If I programmatically grant access to a private flavor for the admin tenant Horizon won't show it.
However nova flavor-access-list --flavor will show the correct list of tenants.
Example

        self.nova().flavor_access.add_tenant_access(flavor, tenant)
        self.nova().flavor_access.add_tenant_access(flavor, 'admin')

will result in nova flavor-access-list --flavor 1987b9ea-32d7-4d64-8174-1039e380de92 showing

+--------------------------------------+----------------------------------+
| Flavor_ID | Tenant_ID |
+--------------------------------------+----------------------------------+
| 1987b9ea-32d7-4d64-8174-1039e380de92 | 64382b768c8b45fe9b46faf2ae5dcb68 |
| 1987b9ea-32d7-4d64-8174-1039e380de92 | admin |
+--------------------------------------+----------------------------------+

However Horizon will only show the 64382b768c8b45fe9b46faf2ae5dcb68 tenant in the flavor access list.

Revision history for this message
Julie Pichon (jpichon) wrote :

Is 'admin' the actual ID for your 'admin' tenant? I can see similar results if I use the word 'admin' instead of the tenant ID, it seems Nova doesn't validate the tenant's existence. Does it work when using the ID instead?

Changed in horizon:
status: New → Incomplete
Revision history for this message
Dimitri Mazmanov (sorantis) wrote :

Yes, I can confirm that. When I use the ID of the admin tenant everything works flawlessly.
One question though. Given that the tenant names must be unique shouldn't I be able to grant access given the tenant name?

Revision history for this message
Dimitri Mazmanov (sorantis) wrote :

Which leads me to think that it's more of a nova issue, rather than Horizon's

Revision history for this message
Julie Pichon (jpichon) wrote :

Indeed, this isn't something we can fix from the Horizon side. Thanks!

Changed in horizon:
status: Incomplete → Invalid
Revision history for this message
Dimitri Mazmanov (sorantis) wrote :

I'd like to come back to this one..
The issue that I still see here is that when I use CLI to check the list of assigned tenants I can see admin (please have a look at the example in the bug description). So I believe Nova does it correctly. But Horizon doesn't pick it up. It just shows the list of the assigned tenants by ID, not by name.
I'm trying to understand the ownership of this issues. Is it really Nova?

Changed in horizon:
status: Invalid → Opinion
Revision history for this message
Julie Pichon (jpichon) wrote :

The strings added this way are meaningless, I think it's correct for Horizon not to show them as they will cause confusion (e.g. thinking a tenant is added to the access list when it is not).

If I do "nova flavor-access-add 42 blahblahblah", "blahblahblah" appears in the list on the CLI even though it is not a tenant name.

If I do "nova flavor-access-add 42 demo", my users in the demo tenant still cannot see the flavor when I do "nova flavor-list" - the tenant was not given access.

It only works correctly when adding access using a tenant id, as far as I can tell.

I'm usually in favour of keeping as consistent with the APIs / CLI tools as possible, but I don't think there is a point in updating Horizon to also show output that we know is in error. I think this should be fixed in the nova and/or novaclient project. I filed bug 1317515 to track this.

Changed in horizon:
status: Opinion → Won't Fix
Revision history for this message
Dimitri Mazmanov (sorantis) wrote :

Good point. Thanks for filing a bug in nova!

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.