Skip to content

Commit

Permalink
Fixed some nits for microversion 2.48
Browse files Browse the repository at this point in the history
The main piece of code for microversion 2.48 was merged.
This patch fixes some nits in docs and error messages.

Change-Id: I8bc5010c255494d4e1bf36272215422991264c6d
  • Loading branch information
niksv authored and mriedem committed Jun 6, 2017
1 parent 3ce0a05 commit 41d6d77
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions api-ref/source/diagnostics.inc
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ will be reported as ``None`` in the response.
- disk_details: disk_details_diagnostics
- nic_details: nic_details_diagnostics

**Example Server diagnostics**
**Example Server diagnostics (2.48)**

.. literalinclude:: ../../doc/api_samples/os-server-diagnostics/v2.48/server-diagnostics-get-resp.json
:language: javascript
Expand All @@ -62,7 +62,7 @@ will be reported as ``None`` in the response.
Before **microversion 2.48** the response format for diagnostics was not
well defined. Each hypervisor had its own format.

**Example Old Server diagnostics**
**Example Server diagnostics (2.1)**

Below is an example of diagnostics for a libvirt based instance. The unit of the return
value is hypervisor specific, but in this case the unit of vnet1_rx* and
Expand Down
2 changes: 1 addition & 1 deletion nova/api/openstack/compute/rest_api_version_history.rst
Original file line number Diff line number Diff line change
Expand Up @@ -562,5 +562,5 @@ user documentation.
Before version 2.48, VM diagnostics response was just a 'blob' of data
returned by each hypervisor. From this version VM diagnostics response is
standardized. It has a set of fields which each hypervisor will try to fill.
If a hypervisor driver unable to provide a specific field then this field
If a hypervisor driver is unable to provide a specific field then this field
will be reported as 'None'.
6 changes: 3 additions & 3 deletions nova/api/openstack/compute/server_diagnostics.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,10 @@ def index(self, req, server_id):
# Diagnostics object. Old compute returns a dictionary. So we
# can't perform a request correctly if compute is too old.
msg = _('Compute node is too old. You must complete the '
'upgrade process to be able to get a standardized '
'upgrade process to be able to get standardized '
'diagnostics data which is available since v2.48. However '
'you still able to get a diagnostics data in old format '
'which is available till v2.47.')
'you are still able to get diagnostics data in '
'non-standardized format which is available until v2.47.')
raise webob.exc.HTTPBadRequest(explanation=msg)
except NotImplementedError:
common.raise_feature_not_supported()
2 changes: 1 addition & 1 deletion nova/exception.py
Original file line number Diff line number Diff line change
Expand Up @@ -2021,7 +2021,7 @@ class AttachInterfaceNotSupported(Invalid):


class InstanceDiagnosticsNotSupported(Invalid):
msg_fmt = _("Instance diagnostics is not supported by compute node.")
msg_fmt = _("Instance diagnostics are not supported by compute node.")


class InvalidReservedMemoryPagesOption(Invalid):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
features:
- Added microversion v2.48 which standardize VM diagnostics response.
It has a set of fields which each hypervisor will try to fill.
If a hypervisor driver unable to provide a specific field then this field
will be reported as 'None'.
If a hypervisor driver is unable to provide a specific field then this
field will be reported as 'None'.

0 comments on commit 41d6d77

Please sign in to comment.