Use OS::Nova::Server resource type for instance metadata

Horizon currently uses the OS::Nova::Instance resource type when
querying for instance metadata, but it should use OS::Nova::Server
to align with Heat and Searchlight.

See also:
  https://review.openstack.org/272271

Closes-Bug: #1537903
Change-Id: I1deab8ed74515d08301e68bd2c75604d35592c50
This commit is contained in:
Justin Pomeroy 2016-02-03 09:06:45 -06:00
parent ba2bc3503e
commit e19bb206bb
5 changed files with 6 additions and 6 deletions

View File

@ -544,7 +544,7 @@
flavor: ['OS::Nova::Flavor', ''],
image: ['OS::Glance::Image', ''],
volume: ['OS::Cinder::Volumes', ''],
instance: ['OS::Nova::Instance', 'metadata']
instance: ['OS::Nova::Server', 'metadata']
};
angular.forEach(resourceTypes, applyForResourceType);

View File

@ -86,7 +86,7 @@
aggregate: 'OS::Nova::Aggregate',
flavor: 'OS::Nova::Flavor',
image: 'OS::Glance::Image',
instance: 'OS::Nova::Instance'
instance: 'OS::Nova::Server'
}[resource]
};
if (propertiesTarget) {

View File

@ -121,7 +121,7 @@
spyOn(glance, 'getNamespaces');
metadataService.getNamespaces('instance', 'metadata');
expect(glance.getNamespaces)
.toHaveBeenCalledWith({ resource_type: 'OS::Nova::Instance',
.toHaveBeenCalledWith({ resource_type: 'OS::Nova::Server',
properties_target: 'metadata' }, false);
});

View File

@ -307,7 +307,7 @@
*
* @param {string} params.properties_target
* The properties target, if the resource type has more than one type
* of property. For example, the OS::Nova::Instance resource type has
* of property. For example, the OS::Nova::Server resource type has
* "metadata" and "scheduler_hints" properties targets.
*
* @param {boolean} params.paginate
@ -359,7 +359,7 @@
* The listing result is an object with property "items".
* Each item is a resource type. Resource types are Strings that
* correlate to Heat and Searchlight resource types.
* For example: OS::Glance::Image and OS::Nova::Instance.
* For example: OS::Glance::Image and OS::Nova::Server.
*
*/
function getResourceTypes() {

View File

@ -2,4 +2,4 @@
features:
- Added the Metadata tab to the new Launch Instance workflow to allow adding
key-value metadata to an instance at launch. This includes any properties
from the OS::Nova::Instance namespace of the glance metadata definitions.
from the OS::Nova::Server namespace of the glance metadata definitions.