From bca44bcefc6fc67d50d4fd63a948726a35c54f5b Mon Sep 17 00:00:00 2001 From: Sam Betts Date: Wed, 2 Aug 2017 13:32:27 +0100 Subject: [PATCH] Switch API ref to use versionadded syntax throughout Sphinx provides the versionadded syntax for indicating version related changes in documentation, the OpenStack doc theme is designed to handle this and render it nicely. This patch switches our inconsistent references to API version related change in the API ref to use this syntax so that it standardised through out the docs, and is more obvious in the documentation itself. Change-Id: Ied6f22deecebd71042d2230b81e057543db3d3f4 --- api-ref/source/baremetal-api-v1-drivers.inc | 28 ++-- api-ref/source/baremetal-api-v1-misc.inc | 18 ++- .../baremetal-api-v1-node-management.inc | 6 +- .../baremetal-api-v1-nodes-portgroups.inc | 6 +- .../source/baremetal-api-v1-nodes-ports.inc | 27 ++-- .../source/baremetal-api-v1-nodes-vifs.inc | 10 +- .../source/baremetal-api-v1-nodes-volume.inc | 6 +- api-ref/source/baremetal-api-v1-nodes.inc | 116 +++++++------- .../baremetal-api-v1-portgroups-ports.inc | 13 +- .../source/baremetal-api-v1-portgroups.inc | 10 +- api-ref/source/baremetal-api-v1-ports.inc | 80 +++++----- api-ref/source/baremetal-api-v1-volume.inc | 10 +- api-ref/source/baremetal-api-versions.inc | 7 + api-ref/source/parameters.yaml | 142 +++++++----------- 14 files changed, 242 insertions(+), 237 deletions(-) diff --git a/api-ref/source/baremetal-api-v1-drivers.inc b/api-ref/source/baremetal-api-v1-drivers.inc index 4e4d4b2289..439a043160 100644 --- a/api-ref/source/baremetal-api-v1-drivers.inc +++ b/api-ref/source/baremetal-api-v1-drivers.inc @@ -4,6 +4,9 @@ Drivers (drivers) ================= +.. versionchanged:: 1.30 + The REST API now also exposes information about *dynamic* drivers. + Ironic has two types of drivers: *classic* drivers and *dynamic* drivers. A *classic* driver is a Python object containing all the logic to manage the @@ -12,15 +15,13 @@ more ``ironic-conductor`` services. Each driver contains a pre-determined set of instantiated interfaces. Each type of interface (eg, ``power`` or ``boot``) performs a specific hardware function. -As of API version 1.30, the REST API also exposes information about *dynamic* -drivers. *Dynamic* drivers are supported via hardware types, which are Python -classes enabled via entry points. Unlike *classic* drivers, which have -pre-determined interfaces, a hardware type may support multiple types of -interfaces. For example, the ``ipmi`` hardware type may support multiple -methods for enabling node console. Which interface a node of a particular -hardware type uses is determined at runtime. This collection of interfaces is -called a *dynamic* driver. For more information about this, see the node API -documentation. +*Dynamic* drivers are supported via hardware types, which are Python classes +enabled via entry points. Unlike *classic* drivers, which have pre-determined +interfaces, a hardware type may support multiple types of interfaces. For +example, the ``ipmi`` hardware type may support multiple methods for enabling +node console. Which interface a node of a particular hardware type uses is +determined at runtime. This collection of interfaces is called a *dynamic* +driver. For more information about this, see the node API documentation. The REST API exposes the list of drivers and which ``ironic-conductor`` processes have loaded that driver via the Driver resource (``/v1/drivers`` @@ -73,8 +74,9 @@ drivers supported by this Ironic service. - links: links - properties: driver_property_links -Additionally, if the request has the "detail" URL parameter set to true, each -driver will also include the following fields. +.. versionchanged:: 1.30 + If the request has the "detail" URL parameter set to true, each + driver will also include the following fields. .. rest_parameters:: parameters.yaml @@ -201,14 +203,14 @@ The following example is returned from the ``agent_ipmitool`` driver. Show driver logical disk properties =================================== +.. versionadded:: 1.12 + .. rest_method:: GET /v1/drivers/{driver_name}/raid/logical_disk_properties Show the required and optional parameters that ``driver_name`` expects to be supplied in the node's ``raid_config`` field, if a RAID configuration change is requested. -This resource was added in API microversion 1.12. - Normal response codes: 200 Request diff --git a/api-ref/source/baremetal-api-v1-misc.inc b/api-ref/source/baremetal-api-v1-misc.inc index f86dcc3ecc..5bbc2e9be0 100644 --- a/api-ref/source/baremetal-api-v1-misc.inc +++ b/api-ref/source/baremetal-api-v1-misc.inc @@ -31,9 +31,11 @@ Agent Lookup .. rest_method:: GET /v1/lookup -Beginning with the v1.22 API, a ``/lookup`` method is exposed at the root of -the REST API. This should only be used by the ``ironic-python-agent`` ramdisk -to retrieve required configuration data from the Bare Metal service. +.. versionadded:: 1.22 + +A ``/lookup`` method is exposed at the root of the REST API. This should only +be used by the ``ironic-python-agent`` ramdisk to retrieve required +configuration data from the Bare Metal service. By default, ``/v1/lookup`` will only match Nodes that are expected to be running the ``ironic-python-agent`` ramdisk (for instance, because the Bare @@ -82,10 +84,12 @@ Agent Heartbeat .. rest_method:: POST /v1/heartbeat/{node_ident} -Beginning with the v1.22 API, a ``/heartbeat`` method is exposed at the root of -the REST API. This is used as a callback from within the ``ironic-python-agent`` -ramdisk, so that an active ramdisk may periodically contact the Bare Metal -service and provide the current URL at which to contact the agent. +.. versionadded:: 1.22 + +A ``/heartbeat`` method is exposed at the root of the REST API. This is used +as a callback from within the ``ironic-python-agent`` ramdisk, so that an +active ramdisk may periodically contact the Bare Metal service and provide +the current URL at which to contact the agent. Normal response codes: 202 diff --git a/api-ref/source/baremetal-api-v1-node-management.inc b/api-ref/source/baremetal-api-v1-node-management.inc index 38341fff7b..c443a73ea1 100644 --- a/api-ref/source/baremetal-api-v1-node-management.inc +++ b/api-ref/source/baremetal-api-v1-node-management.inc @@ -228,6 +228,8 @@ Inject NMI (Non-Masking Interrupts) .. rest_method:: PUT /v1/nodes/{node_ident}/management/inject_nmi +.. versionadded:: 1.29 + Inject NMI (Non-Masking Interrupts) for the given Node. This feature can be used for hardware diagnostics, and actual support depends on a driver. @@ -365,6 +367,8 @@ Set RAID Config .. rest_method:: PUT /v1/nodes/{node_ident}/states/raid +.. versionadded:: 1.12 + Store the supplied configuration on the Node's ``target_raid_config`` property. This property must be structured JSON, and will be validated by the driver upon receipt. The request schema is defined in the `documentation for the RAID feature `_ @@ -372,8 +376,6 @@ schema is defined in the `documentation for the RAID feature