Hypervisors collection_name affects pagination query
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Low
|
Fan Zhang | ||
Rocky |
Fix Released
|
Undecided
|
Unassigned | ||
Stein |
Fix Released
|
Undecided
|
Unassigned | ||
Train |
Fix Released
|
Undecided
|
Unassigned | ||
OpenStack SDK |
New
|
Undecided
|
Unassigned |
Bug Description
In nova, hypervisor view builder's collect_name is 'hypervisors':
```
# nova.api.
class ViewBuilder(
_collection
def get_links(self, request, hypervisors, detail=False):
coll_name = (self._
return self._get_
```
So when we do paginated query via openstacksdk, we would get response like this:
```
{u'hypervisors': [{u'status': u'enabled', u'state': u'up', u'id': u'53fb5bdc-
```
And openstacksdk uses wrong hypervisors_links to query next page, and get error:
```
Traceback (most recent call last):
File "p_hypervisors-
do_
File "p_hypervisors-
srvs = [i for i in info]
File "/usr/lib/
exceptions.
File "/usr/lib/
http_
openstack.
```
The right uri should be `/v2.1/
Changed in nova: | |
assignee: | nobody → Fan Zhang (fanzhang) |
summary: |
- Hypervisors collection_name effects pagination query + Hypervisors collection_name affects pagination query |
Changed in nova: | |
importance: | Undecided → Low |
Fix proposed to branch: master /review. opendev. org/709431
Review: https:/