Update REST API doc for Ceph External Backend

Story: 2002820
Task: 22737

Change-Id: I367070c3ed8970396fe9f3a79a18249098517e63
Signed-off-by: Don Penney <don.penney@windriver.com>
Signed-off-by: Jack Ding <jack.ding@windriver.com>
This commit is contained in:
Wei Zhou 2018-06-27 15:28:39 -04:00 committed by Jack Ding
parent 763f3ccf0e
commit d3e6c4efe0
9 changed files with 325 additions and 1 deletions

View File

@ -1144,6 +1144,26 @@ configuration entity for the system.
href="../wadls/sysinv-api/v1/sysinv-api-v1.wadl#storage_ceph_id">
<wadl:method href="#deleteStorageCeph"/>
</wadl:resource>
<wadl:resource
href="../wadls/sysinv-api/v1/sysinv-api-v1.wadl#storage_ceph_external">
<wadl:method href="#listStorageCephExternals"/>
</wadl:resource>
<wadl:resource
href="../wadls/sysinv-api/v1/sysinv-api-v1.wadl#storage_ceph_external">
<wadl:method href="#addStorageCephExternal"/>
</wadl:resource>
<wadl:resource
href="../wadls/sysinv-api/v1/sysinv-api-v1.wadl#storage_ceph_external_id">
<wadl:method href="#getStorageCephExternal"/>
</wadl:resource>
<wadl:resource
href="../wadls/sysinv-api/v1/sysinv-api-v1.wadl#storage_ceph_external_id">
<wadl:method href="#modifyStorageCephExternal"/>
</wadl:resource>
<wadl:resource
href="../wadls/sysinv-api/v1/sysinv-api-v1.wadl#storage_ceph_external_id">
<wadl:method href="#deleteStorageCephExternal"/>
</wadl:resource>
<wadl:resource
href="../wadls/sysinv-api/v1/sysinv-api-v1.wadl#storage_file">
<wadl:method href="#listStorageFiles"/>

View File

@ -0,0 +1,7 @@
{
"services": "cinder",
"confirmed": true,
"name": "ceph-ext-bk",
"ceph_conf": "ext-ceph.conf",
"capabilities": {"cinder_pool": "cinder-volumes"}
}

View File

@ -0,0 +1,25 @@
{
"confirmed": false,
"task": null,
"name": "ceph-ext-bk",
"links": [
{
"href": "http://192.168.204.2:6385/v1/storage_ceph_external/ced40c30-5499-48a7-8197-3e1a90b3f402",
"rel": "self"
},
{
"href": "http://192.168.204.2:6385/storage_ceph_external/ced40c30-5499-48a7-8197-3e1a90b3f402",
"rel": "bookmark"
}
],
"created_at": "2018-06-27T13:30:38.557700+00:00",
"updated_at": null,
"uuid": "ced40c30-5499-48a7-8197-3e1a90b3f402",
"capabilities": {
"cinder_pool": "cinder-volumes"
},
"ceph_conf": null,
"state": "configuring",
"services": "cinder",
"backend": "ceph-external"
}

View File

@ -0,0 +1,27 @@
{
"storage_ceph_external": [
{
"task": null,
"uuid": "ced40c30-5499-48a7-8197-3e1a90b3f402",
"links": [
{
"href": "http://192.168.204.2:6385/v1/storage_backends/ced40c30-5499-48a7-8197-3e1a90b3f402",
"rel": "self"
},
{
"href": "http://192.168.204.2:6385/storage_backends/ced40c30-5499-48a7-8197-3e1a90b3f402",
"rel": "bookmark"
}
],
"created_at": "2018-06-27T13:30:38.557700+00:00",
"updated_at": "2018-06-27T13:35:13.213177+00:00",
"capabilities": {
"cinder_pool": "cinder-volumes"
},
"services": "cinder",
"state": "configured",
"backend": "ceph-external",
"name": "ceph-ext-bk"
}
]
}

View File

@ -0,0 +1,12 @@
[
{
"path": "/services",
"value": "cinder,glance",
"op": "replace"
}
{
"path": "/capabilities",
"value": "{\\"glance_pool\\": \\"images\\"}",
"op": "replace"
}
]

View File

@ -0,0 +1,27 @@
{
"confirmed": false,
"task": null,
"uuid": "ced40c30-5499-48a7-8197-3e1a90b3f402",
"links": [
{
"href": "http://192.168.204.2:6385/v1/storage_ceph_external/ced40c30-5499-48a7-8197-3e1a90b3f402",
"rel": "self"
},
{
"href": "http://192.168.204.2:6385/storage_ceph_external/ced40c30-5499-48a7-8197-3e1a90b3f402",
"rel": "bookmark"
}
],
"created_at": "2018-06-27T13:30:38.557700+00:00",
"updated_at": "2018-06-27T13:35:13.213177+00:00",
"capabilities": {
"glance_pool": "images",
"cinder_pool": "cinder-volumes"
},
"name": "ceph-ext-bk",
"services": "cinder,glance",
"state": "configured",
"ceph_conf": "ext-ceph.conf",
"backend": "ceph-external"
}

View File

@ -0,0 +1,26 @@
{
"confirmed": false,
"task": null,
"uuid": "ced40c30-5499-48a7-8197-3e1a90b3f402",
"links": [
{
"href": "http://192.168.204.2:6385/v1/storage_ceph_external/ced40c30-5499-48a7-8197-3e1a90b3f402",
"rel": "self"
},
{
"href": "http://192.168.204.2:6385/storage_ceph_external/ced40c30-5499-48a7-8197-3e1a90b3f402",
"rel": "bookmark"
}
],
"created_at": "2018-06-27T13:30:38.557700+00:00",
"updated_at": "2018-06-27T13:35:13.213177+00:00",
"capabilities": {
"cinder_pool": "cinder-volumes"
},
"name": "ceph-ext-bk",
"services": "cinder",
"state": "configured",
"ceph_conf": "ext-ceph.conf",
"backend": "ceph-external"
}

View File

@ -2200,7 +2200,7 @@
<para>Additional capabilities info about the storage function.</para>
</wadl:doc>
</param>
<param xmlns="http://wadl.dev.java.net/2009/02"
<param xmlns="http://wadl.dev.java.net/2009/02"
name="function" style="plain" type="xsd:string" >
<wadl:doc xmlns="http://docbook.org/ns/docbook"
xmlns:wadl="http://wadl.dev.java.net/2009/02" xml:lang="EN">
@ -3765,6 +3765,18 @@
</param>
'>
<!-- Ceph External Storage Backend Show/Modify Extra Parameters -->
<!ENTITY storageCephExternalParameters '
<param xmlns="http://wadl.dev.java.net/2009/02"
name="ceph_conf" style="plain" type="xsd:integer" >
<wadl:doc xmlns="http://docbook.org/ns/docbook"
xmlns:wadl="http://wadl.dev.java.net/2009/02" xml:lang="EN">
<para>The Ceph External configuration file.</para>
</wadl:doc>
</param>
'>
<!-- File Storage Backend Show/Modify Extra Parameters -->
<!ENTITY storageFileParameters '

View File

@ -876,6 +876,24 @@ SPDX-License-Identifier: Apache-2.0
</resource>
</resource>
<!-- /v1/storage_ceph_external -->
<resource id="storage_ceph_external" path="storage_ceph_external" >
<method href="#listStorageCephExternals"/>
<method href="#addStorageCephExternal"/>
<!-- /v1/storage_ceph_external/{storage_ceph_external_id} -->
<resource id="storage_ceph_external_id" path="{storage_ceph_external_id}" >
<param name="storage_ceph_external_id" style="template" required="true" type="csapi:UUID">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
<para>The unique identifier of the storage backend.</para>
</wadl:doc>
</param>
<method href="#getStorageCephExternal"/>
<method href="#modifyStorageCephExternal"/>
<method href="#deleteStorageCephExternal"/>
</resource>
</resource>
<!-- /v1/storage_file -->
<resource id="storage_file" path="storage_file" >
<method href="#listStorageFiles"/>
@ -6314,6 +6332,156 @@ OAM Controller-1 IP Address.</para>
</response>
</method>
<!-- ..................................................... -->
<!-- .. Storage Backends - Ceph External .. -->
<!-- ..................................................... -->
<method name="GET" id="listStorageCephExternals">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN"
title="List Ceph External storage backends">
<para role="shortdesc">List Ceph External storage backends.</para>
</wadl:doc>
<response status="200">
<representation mediaType="application/xml">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
</wadl:doc>
&storageBackendListParameters;
&storageCephExternalParameters;
&commonListShowParameters;
</representation>
<representation mediaType="application/json">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
<xsdxt:code href="api_samples/storage_ceph_external_list-response.json"/>
</wadl:doc>
</representation>
</response>
&commonFaults; &getFaults;
</method>
<method name="GET" id="getStorageCephExternal">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN"
title="Show Ceph External storage backend">
<para role="shortdesc">Shows attributes of the Ceph External storage backend.</para>
</wadl:doc>
<response status="200">
<representation mediaType="application/xml">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
</wadl:doc>
&storageBackendListParameters;
&storageCephExternalParameters;
&commonListShowParameters;
</representation>
<representation mediaType="application/json">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
<xsdxt:code href="api_samples/storage_ceph_external_show-response.json"/>
</wadl:doc>
</representation>
</response>
&commonFaults; &getFaults;
</method>
<method name="POST" id="addStorageCephExternal">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN"
title="Add a Ceph External storage backend">
<para role="shortdesc">Add a Ceph External storage backend.</para>
<para></para>
</wadl:doc>
<request>
<representation mediaType="application/xml">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
</wadl:doc>
<param xmlns="http://wadl.dev.java.net/2009/02"
name="backend" style="plain" type="xsd:string" >
<wadl:doc xmlns="http://docbook.org/ns/docbook"
xmlns:wadl="http://wadl.dev.java.net/2009/02" xml:lang="EN">
<para>This parameter specifies the type of the backend.
Valid values are (is): <code>ceph-external</code>
</para>
</wadl:doc>
</param>
<param xmlns="http://wadl.dev.java.net/2009/02"
name="name" style="plain" type="xsd:string" >
<wadl:doc xmlns="http://docbook.org/ns/docbook"
xmlns:wadl="http://wadl.dev.java.net/2009/02" xml:lang="EN">
<para>This parameter specifies the name of the backend.
</para>
</wadl:doc>
</param>
&storageBackendModifyParameters;
&storageCephExternalParameters;
</representation>
<representation mediaType="application/json">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
<xsdxt:code href="api_samples/storage_ceph_external_add-request.json"/>
</wadl:doc>
</representation>
</request>
<response status="200">
<representation mediaType="application/xml">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
</wadl:doc>
&storageBackendListParameters;
&storageCephExternalParameters;
&commonListShowParameters;
</representation>
<representation mediaType="application/json">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
<xsdxt:code href="api_samples/storage_ceph_external_add-response.json"/>
</wadl:doc>
</representation>
</response>
&postPutFaults;
</method>
<method name="PATCH" id="modifyStorageCephExternal">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN"
title="Modify Ceph External storage backend">
<para role="shortdesc">Modifies the Ceph External storage backend.</para>
</wadl:doc>
<request>
<representation mediaType="application/xml">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
</wadl:doc>
&storageBackendModifyParameters;
&storageCephExternalParameters;
</representation>
<representation mediaType="application/json">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
<xsdxt:code href="api_samples/storage_ceph_external_modify-request.json"/>
</wadl:doc>
</representation>
</request>
<response status="200">
<representation mediaType="application/xml">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
</wadl:doc>
&storageBackendListParameters;
&storageCephExternalParameters;
&commonListShowParameters;
</representation>
<representation mediaType="application/json">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
<xsdxt:code href="api_samples/storage_ceph_external_modify-response.json"/>
</wadl:doc>
</representation>
</response>
&postPutFaults;
</method>
<method name="DELETE" id="deleteStorageCephExternal">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN"
title="Delete ceph External storage backend">
<para role="shortdesc">Deletes a ceph External storage backend.</para>
</wadl:doc>
<response status="204">
<representation mediaType="application/json">
<wadl:doc xmlns="http://docbook.org/ns/docbook" xml:lang="EN">
</wadl:doc>
</representation>
</response>
</method>
<!-- ..................................................... -->
<!-- .. Storage Backends - File .. -->
<!-- ..................................................... -->