Use admin neutron client to gather port resource requests
The network_api get_requested_resource_for_instance() creates a neutron
client with the current request context and uses the client to query
neutron ports. Neutron does not return the resource_request of the
neutron port if it is queried by a non-admin. So if the request context
was a non admin context nova thought that none of the ports have resource
requests.
This patch ensures that an admin client is used to query the ports.
Reviewed: https:/ /review. opendev. org/691005 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=38a214466fa 2cccc3808ca6d7d 7140cf56f733ba
Committed: https:/
Submitter: Zuul
Branch: master
commit 38a214466fa2ccc c3808ca6d7d7140 cf56f733ba
Author: Balazs Gibizer <email address hidden>
Date: Thu Oct 24 17:31:45 2019 +0200
Use admin neutron client to gather port resource requests
The network_api get_requested_ resource_ for_instance( ) creates a neutron
client with the current request context and uses the client to query
neutron ports. Neutron does not return the resource_request of the
neutron port if it is queried by a non-admin. So if the request context
was a non admin context nova thought that none of the ports have resource
requests.
This patch ensures that an admin client is used to query the ports.
Change-Id: I1178fb77a74010 c3b9f51eea22c7e 7576b600015
Closes-Bug: #1849695