Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 808276 - python-routes causes issues with the nova openstack REST API
Summary: python-routes causes issues with the nova openstack REST API
Keywords:
Status: CLOSED CANTFIX
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: python-routes
Version: 6.2
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Pádraig Brady
QA Contact: qe-baseos-daemons
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-03-30 02:41 UTC by Pádraig Brady
Modified: 2016-01-04 14:46 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-11-28 16:59:38 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Pádraig Brady 2012-03-30 02:41:39 UTC
Description of problem:
`nova flavor-list` returns 404.

Enabling debugging shows that the requested flavor URL is being routed incorrectly.

2012-03-30 03:00:36,624 DEBUG routes.middleware [1d8a7ffa-fb80-492b-8fe3-f147b532d81c admin admin] Matched GET /admin/flavors/detail from (pid=4177) __call__ /usr/lib/python2.6/site-packages/routes/middleware.py:97
2012-03-30 03:00:36,625 DEBUG routes.middleware [1d8a7ffa-fb80-492b-8fe3-f147b532d81c admin admin] Route path: '/{project_id}/flavors/:flavor_id/os-extra_specs/:(id)', defaults: {'action': u'show', 'controller': <nova.api.openstack.wsgi.Resource object at 0x2527290>, 'id': 
None} from (pid=4177) __call__ /usr/lib/python2.6/site-packages/routes/middleware.py:99
2012-03-30 03:00:36,625 DEBUG routes.middleware [1d8a7ffa-fb80-492b-8fe3-f147b532d81c admin admin] Match dict: {'action': u'show', 'controller': <nova.api.openstack.wsgi.Resource object at 0x2527290>, 'project_id': u'admin', 'flavor_id': u'detail', 'id': None} from (pid=417
7) __call__ /usr/lib/python2.6/site-packages/routes/middleware.py:100


I rebuilt python-routes-1.12.3 for RHEL 6.2 and it worked fine.


2012-03-30 03:32:48,069 DEBUG routes.middleware [c77cb299-02b3-4110-9099-50bff5f6ddd0 admin admin] No route matched for GET /admin/flavors/detail from (pid=5902) __call__ /usr/lib/python2.6/site-packages/routes/middleware.py:97
2012-03-30 03:32:48,118 DEBUG routes.middleware [c77cb299-02b3-4110-9099-50bff5f6ddd0 admin admin] Matched GET /admin/flavors/detail from (pid=5902) __call__ /usr/lib/python2.6/site-packages/routes/middleware.py:100
2012-03-30 03:32:48,119 DEBUG routes.middleware [c77cb299-02b3-4110-9099-50bff5f6ddd0 admin admin] Route path: '/{project_id}/flavors/detail', defaults: {'action': u'detail', 'controller': <nova.api.openstack.wsgi.Resource object at 0x2ae2d50>} from (pid=5902) __call__ /usr/lib/python2.6/site-packages/routes/middleware.py:102
2012-03-30 03:32:48,119 DEBUG routes.middleware [c77cb299-02b3-4110-9099-50bff5f6ddd0 admin admin] Match dict: {'action': u'detail', 'controller': <nova.api.openstack.wsgi.Resource object at 0x2ae2d50>, 'project_id': u'admin'} from (pid=5902) __call__ /usr/lib/python2.6/site-packages/routes/middleware.py:103


A workaround for openstack-nova is to remove:
/usr/lib/python2.6/site-packages/nova/api/openstack/contrib/flavorextraspecs.py
though there may be other issue not encountered yet.

Comment 2 Pádraig Brady 2012-04-10 17:50:46 UTC
The above issue impacted openstack diablo.

For reference another issue affecting the openstack essex release is,
this glance command:

glance -N http://192.168.122.106:5000/v2.0 -T glance-users -I admin -K secrete index

will throw:

File "/usr/lib/python2.6/site-packages/glance/api/middleware/cache_manage.py", line 80, in process_request
match = self._mapper.match(request.path, request.environ)

That's because the newer python-routes takes the environ parameter,
while the older does not.

Comment 3 RHEL Program Management 2012-09-07 05:08:41 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated
in the current release, Red Hat is unable to address this
request at this time.

Red Hat invites you to ask your support representative to
propose this request, if appropriate, in the next release of
Red Hat Enterprise Linux.

Comment 4 Alan Pevec 2013-11-28 16:59:38 UTC
This was solved by introducing parallel installable python-routes1.12 package in EPEL6 and RHOS.


Note You need to log in before you can comment on or make changes to this bug.