API calls in openstack_dashboard.usage.quotas should be wrapped with try/except

Bug #1383580 reported by Akihiro Motoki
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Dashboard (Horizon)
Fix Released
Low
Vishal Manchanda

Bug Description

API calls in openstack_dashboard.usage.quotas should be wrapped with try/except.

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

I think this is somewhat of a duplicate of bug 1249330 (which has a patch up for review)?

Revision history for this message
Akihiro Motoki (amotoki) wrote :

This is raised in a review https://review.openstack.org/#/c/129689/ which reduces the complexity of the code.

I was not aware of bug 1249330. Two bugs are similar but I think they are different.
bug 1249330 reports if retrieving quotas from Neutron fails quotas from other projects also fail,
but this bug reports errors from nova/cinder API calls are not caught.
The fix might be done in a single patch.

Changed in horizon:
assignee: nobody → Martin Hickey (martin-hickey)
Revision history for this message
Prabhjyot Singh Sodhi (psd0) wrote :

As a newbie to open source I would love to try a stab at this bug.
Are you still working on this Martin?

Changed in horizon:
status: New → In Progress
assignee: Martin Hickey (martin-hickey) → Prabhjyot Singh Sodhi (psd0)
Revision history for this message
Sean Workman (sean-workman-14) wrote :

I'd like to work on this task, has it already been completed?

Changed in horizon:
assignee: Prabhjyot Singh Sodhi (psd0) → Annapoornima Koppad (annakoppad)
Revision history for this message
Andrew Lenards (lenards) wrote :

I was just reviewing the source in question (openstack_dashboard/usage/quotas.py), and wrapping all the calls might harm the readability. Is there any chance an object proxy approach could be used to wrap {base, cinder, network, neturon, nova}? Similar, sort of, to decorating, but would allow you to intercept the calls and wrap them w/ the desired try/except.

I would imagine the concerns for such an approach would be:
- added overhead to the function calls
- adding new dependency (something like wrapt [0], perhaps)

[0] http://wrapt.readthedocs.io/en/latest/wrappers.html#object-proxy

Changed in horizon:
assignee: Annapoornima Koppad (annakoppad) → Vishal Manchanda (vishalmanchanda)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/horizon 19.1.0

This issue was fixed in the openstack/horizon 19.1.0 release.

Revision history for this message
Vishal Manchanda (vishalmanchanda) wrote :
Changed in horizon:
status: In Progress → Fix Released
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.