147 Commits

Author SHA1 Message Date
whoami-rajat
c5c5c009ff Automate generation of API versions api-ref samples
This patch adds Tests for the following :

1) API versions
2) API extensions

Change-Id: Ieaa1e2768c091b93c7afcbf04ec4a181cb021ec5
Partially-Implements: blueprint generating-sample-files
2019-01-10 19:48:18 +05:30
Zuul
906acbc8a0 Merge "api-ref: fix some issues in volumes interfaces" 2019-01-09 02:40:18 +00:00
Zuul
5ea88854cc Merge "api-ref: add missing volumes_links in list-volume interfaces" 2018-12-19 01:59:32 +00:00
Zuul
dad7796622 Merge "Add user_id in backup list and show API" 2018-12-19 01:14:12 +00:00
zhangbailin
03867e3e89 Add user_id in backup list and show API
Add ``user_id`` to response body of list backup with detail and show
backup detail APIs. In this way, you can get the ``user_id`` in backup
list or show response, make the admin/user easy to manage backup file.

Blueprint: add-user-id-attribute-to-backup-response
Change-Id: I3ffb544ef3ee65276cee8b1e870d524fd0e57085
2018-12-12 00:52:05 -05:00
whoami-rajat
67150217c9 Automate generation of api-ref samples
This patch adds the following functionality:

1) Base framework for test cases
2) Volume type tests

Change-Id: I0e51bcc8c634923ca6fcff99a9f40b786933caa5
Partially-Implements: blueprint generating-sample-files
2018-12-06 12:19:55 +05:30
zhufl
7fba6fdc4b api-ref: fix some issues in volumes interfaces
1. group_id is missing from the response of list-voluems and create_volume.

2. shared_targets and service_uuid are new in 3.48

3. migration_status, os-vol-host-attr:host, os-vol-mig-status-attr:migstat,
   and os-vol-mig-status-attr:name_id may not always be present, so they
   should be optional parameters.

https://developer.openstack.org/api-ref/block-storage/v3/index.html?expanded=reset-a-backup-s-status-detail,update-a-backup-detail,create-a-backup-detail#create-a-volume
https://developer.openstack.org/api-ref/block-storage/v3/index.html?expanded=reset-a-backup-s-status-detail,update-a-backup-detail,create-a-backup-detail#show-a-volume-s-details

Change-Id: I11201f2a604818e633eb2000b3c69162c668721d
2018-11-27 13:20:35 +08:00
zhufl
192da355ba api-ref: add missing volumes_links in list-volume interfaces
https://developer.openstack.org/api-ref/block-storage/v3/index.html?expanded=list-accessible-volumes-detail#list-accessible-volumes
https://developer.openstack.org/api-ref/block-storage/v3/index.html?expanded=#list-accessible-volumes-with-details

volumes_links is in the response body of list-volume and
list-volume-with-details when pagination is used. So it should
be an optional parameter.

Change-Id: If61797f9a5cb5c522ed62886f4114d43e7cbbdef
2018-11-09 10:52:18 +08:00
Zuul
d490385dc7 Merge "api-ref: add missing fields in volume group types" 2018-10-26 01:58:45 +00:00
Zuul
e576261f7e Merge "api-ref: fix some inconsistencies in snapshot API" 2018-10-19 19:54:31 +00:00
Zuul
f1525622eb Merge "api-ref: Add response fields and response example for snapshot manage" 2018-10-19 19:54:28 +00:00
zhufl
0f3375689f api-ref: add missing fields in volume group types
There are some fields missing in volume group types api ref,
https://developer.openstack.org/api-ref/block-storage/v3/#list-group-types

is_public and description are missing from the response and
sample of "List group types".

Change-Id: I47c3c8279d2026f04646ceba4bd31f23519fffad
2018-10-17 03:04:01 +00:00
zhufl
5c82ba8b4b api-ref: fix some inconsistencies in snapshot API
https://developer.openstack.org/api-ref/block-storage/v3/index.html#list-snapshots-and-details

1. updated_at is missing in the response fields of show-snapshot
   and list-snapshots
2. id's description is "The UUID of the volume transfer.", which
   is incorrect.
3. volume_id's description is "The UUID of the volume.", which is
   not very accurate.
4. os-extended-snapshot-attributes:progress is something like '100%',
   so it should be string, not integer
5. response fields of show-snapshot-metadata is incorrect.
6. metadata is missing in the response example of update-snapshot
7. snapshots_links is missing in the response of list-snapshot

Change-Id: I0f6994c2d2dc27d3d594acdd460e27c338f86a2c
2018-10-16 10:20:47 +08:00
Zuul
84073fb76e Merge "api-ref: remove created_at from response example of list-transfer" 2018-10-15 18:48:12 +00:00
zhufl
30568ee1af api-ref: Add response fields and response example for snapshot manage
https://developer.openstack.org/api-ref/block-storage/v3/index.html#manage-an-existing-snapshot
Response fields and response example are missing in the
"Manage an existing snapshot" api ref, this is to add them.

Change-Id: I5a3f397e1a4d7e38d35b707f3c164ef7522aea95
2018-10-10 12:23:01 +08:00
Zuul
4fa7a5269d Merge "api-ref: add missing response body for groups" 2018-10-10 02:23:16 +00:00
zhufl
fbf431abe8 api-ref: remove created_at from response example of list-transfer
created_at is only present in "List volume transfers and details", 
and not in "List volume transfers for a project".
https://developer.openstack.org/api-ref/block-storage/v3/index.html#list-volume-transfers-for-a-project
https://developer.openstack.org/api-ref/block-storage/v3/index.html#list-volume-transfers-and-details

So created_at should be removed from the response example of
"List volume transfers for a project".

Change-Id: I52a81454a995920c1ba5534fea3d50f6c9986881
2018-10-10 02:06:21 +00:00
Zuul
4ce1ae6574 Merge "api-ref: total/free_capacity should be with postfix _gb" 2018-10-01 20:02:49 +00:00
zhufl
bb703a9f4d api-ref: add missing response body for groups
1. https://developer.openstack.org/api-ref/block-storage/v3/#create-group
   "Create group" should have response body, like
    {
	"group": {
		"id": "2c311e17-9daa-4229-926a-cb9e233f06b0",
		"name": "tempest-GroupsTest-Group-938181552"
	}
    }

2. https://developer.openstack.org/api-ref/block-storage/v3/#create-group-from-source
   "Create group from source" should have response body, like
    {
        "group": {
                "id": "2c311e17-9daa-4229-926a-cb9e233f06b0",
                "name": "tempest-GroupsTest-Group-938181552"
        }
    }

3. https://developer.openstack.org/api-ref/block-storage/v3/#show-group-details
   group_type in "Show group details" or "List groups with details"
   or "Create group" should be an uuid string, not object.

4. group_snapshot_id and source_group_id should be optional in the
   response of "Show group details".

Change-Id: Iea0c8f0f6fec1b8460c4ea53ed6468adbc31abf2
2018-09-29 17:24:11 +08:00
zhufl
c141210246 api-ref: add missing fields in volume types
There are some fields missing in volume types api ref,
1. https://developer.openstack.org/api-ref/block-storage/v3/index.html#show-volume-type-detail
"os-volume-type-access:is_public" and "qos_specs_id" are missing
from the response of "Show volume type detail".

2. https://developer.openstack.org/api-ref/block-storage/v3/index.html#update-a-volume-type
"id" is missing from the response of "Updates a volume type."

Change-Id: I5f24a344755124fbc429f43a6970be00592a8ef2
2018-09-28 07:30:48 +00:00
zhufl
8fec696bfd api-ref: total/free_capacity should be with postfix _gb
https://developer.openstack.org/api-ref/block-storage/v3/index.html#list-all-back-end-storage-pools
free_capacity and total_capacity in "List all back-end storage pools"
should be free_capacity_gb and total_capacity_gb

Change-Id: Ic0690d12147fa63b903f3442eccde88c1d501711
2018-09-28 15:30:37 +08:00
Zuul
c61f36be76 Merge "api-ref: add docs for os-migrate_volume API" 2018-09-26 00:58:53 +00:00
Matt Riedemann
04ce5179bb api-ref: document no_snapshots default for volume transfer API
This documents the default value (False) for the no_snapshots
parameter to the 3.55 volume transfer API and also fixes the
no_snapshots value in the API sample to use proper json.

Change-Id: I852a04c0b772de64fa82c9c1630dff8ba6454eeb
2018-09-12 14:32:16 -04:00
Matt Riedemann
76cc9bd02b api-ref: add docs for os-migrate_volume API
Adds the v2 and v3 API reference documentation for the
admin-only (by default) os-migrate_volume volume action
API. The only major difference with the v3 API is the
cluster parameter introduced in the 3.16 microversion.

Change-Id: I70f6b2cc4d25ea155ce09ddeec26b995890a2db3
Partial-Bug: #1607539
2018-08-22 20:38:22 -04:00
wanghao
c0efaa1d46 Transfer snapshots with volumes
This feature changes Cinder to transfer
snapshots with volumes at the same time by default.
If user doesn't want to transfer snapshots, they could use
a new optional argument '--no-snapshots' after microversion 3.55.
And we also introduce the new V3 api 'v3/volume_transfers'
to move this API out of contrib into Cinder V3 API.

The cinderclient patch: https://review.openstack.org/#/c/577611/

Change-Id: If848d131e5edcdb77d0b3c2ca45a99c4d5e14d1e
Implements: blueprint transfer-snps-with-vols
2018-07-19 09:42:43 +08:00
Zuul
7959cd24d5 Merge "Add v3 api-ref for force delete snapshot" 2018-06-25 23:42:19 +00:00
Zuul
adf262aef4 Merge "api-ref: Adds os-update_readonly_flag API" 2018-06-22 21:46:10 +00:00
jeremy.zhang
299f4ecd0c Fix v3 sample files
This patch is mainly to fix some v3 sample json files to keep the format consistent.

Change-Id: Ibfe171f19e1530c0fcdc6a531c36871d1bc51a3c
2018-06-22 01:05:08 +08:00
jeremy.zhang
6ba228e2cd Add v3 api-ref for force delete snapshot
This patch is to add v3 api-ref for force delete a snapshot.

Change-Id: I44d16a9fa9065b5e92b18c487b45e7076ec03b0e
2018-06-21 23:34:16 +08:00
Dongcan Ye
cb0cb208e3 api-ref: Adds os-update_readonly_flag API
This patch adds "os-update_readonly_flag" volume action API.

Change-Id: Idad24f9a17af3323a26ed487f1f0d20306bf935f
Closes-Bug: #1775915
Closes-Bug: #1771390
2018-06-21 04:38:16 +00:00
jeremy.zhang
9519e20308 Add v3 api-ref for updating snapshot status
This patch adds v3 api-ref for updating relative fields to status of a snapshot.

Change-Id: I24b8a05c814eb6a69ce957c75b8d168576774380
2018-06-20 19:13:58 +08:00
Zuul
38492b1bba Merge "Add missing volume APIs" 2018-06-12 12:40:52 +00:00
Zuul
e6348f4aef Merge "[Api-ref] fix the type of service_id in worker cleanup api" 2018-06-11 23:40:31 +00:00
liuyamin
e6d4b20656 [Api-ref] fix the type of service_id in worker cleanup api
According to [1], the type of service_id is int, so fix it.

[1]https://review.openstack.org/#/c/569036/

Change-Id: Ie142582a2a73564127be83c1e3531a07311b4153
2018-05-29 14:19:14 +08:00
Dongcan Ye
b8078a8e38 api-ref: Fix v3 API version details error
Show v3 API version details should not return informations about v2,
meanwhile location is not in Response Parameters.

Change-Id: Ida12222b3bdac10d030d56b9724f09ee097c0b3c
2018-05-28 03:54:37 +00:00
liuyamin
cfcd94bc9a Add missing volume APIs
A bunch of volume APIs are missing in current documentation, such
as os-reserve/os-unreserve/os-begin_detaching/os-roll_detaching
os-initialize_connection/os-terminate_connection, this patch is aim to
add the missing APIs.

Change-Id: If0732aa94db4e8cdef30a2be0c53314b507ee002
Closes-bug: #1761049
2018-05-15 20:15:49 +08:00
junboli
bed11c76da [Api-ref] fix incorrect host value in worker cleanup api
The value of host in sample request and sample response is not correct,
this change is to update this.


Change-Id: If8524a08795c222e67ca2c85243a42fb27e43bdb
Close-bug: #1758955
2018-05-15 02:44:52 +00:00
TommyLike
902719a46e Remove extended attribute 'os-volume-replication' in Doc
'os-volume-replication:extended_status' and
'os-volume-replication:driver_date' are unavailable
since the merge of patch [1] during Liberty, remove these
from API document.

[1]: https://review.openstack.org/#/c/275797/

Change-Id: Ib319702f085930a6bf528ef95fb17a7da8451e96
2018-03-31 11:53:21 +08:00
Zuul
517dcf451a Merge "Support cross AZ backups" 2018-03-18 01:26:19 +00:00
Zuul
08cfa44d35 Merge "Add 'metadata' in backup detail&show API document" 2018-03-12 15:36:54 +00:00
Zuul
a900054f26 Merge "Add 'list_volume' in Group show&list API Doc" 2018-03-08 06:39:01 +00:00
TommyLike
1a2a0d4996 Add 'list_volume' in Group show&list API Doc
Add API document for 'list_volume' in Group
show&list APIs.

Code patch: https://review.openstack.org/#/c/409694

Change-Id: Ib328b62c61ec8b8afed3de07020c7ae2bfb163be
2018-03-07 14:50:44 +08:00
Gorka Eguileor
5feaf74ccf Support cross AZ backups
We currently limit backups to the same AZ of the volume while allowing
volume restoration to any AZ.

When having multiple AZs it is ideal to store your backups in a
different AZ than the one where the source volumes are stored.

This patch adds microversion 3.51 where we allow requesting the AZ where
we want to store backups which will allow us to have as many backup AZs
as volume AZs and do cross AZ backups for increased security, this
feature also supports having an additional AZ just for backups or the
less desirable solution where you store all your backups in a single AZ
shared with some of the volumes.

Change-Id: I595932276088d25abd464025c99dce33a2cc502b
2018-02-23 11:35:42 +01:00
zhangbailin
864eab12d6 Fix json data format
Remove extra comma from sample json file.

Change-Id: Id49838597b9e4f59742c1371d5be7159deabb002
2018-02-07 16:57:15 +08:00
TommyLike
934675eca7 Update document for worker cleanup API
Update API document for API 'workers/cleanup',
also remove 'until' from allowed clean keys as
its value is always assigned in code.

Change-Id: Iea940d7c7e52718b8e5e8dcf706aa5d1126860ef
2018-02-02 13:32:34 +00:00
TommyLike
1c20ce2e85 Add 'metadata' in backup detail&show API document
Backup metadata is available in backup list&show
APIs since 3.43, update the document.

Change-Id: I056ed13124cdb64b5be8012898fb038e112fbe86
2018-01-30 17:11:43 +08:00
zhangbailin
23b56315b1 Remove extra spaces of the volume creation request body
Change-Id: I7fc3ccd24cd9e95cb4fa1d70658fe064cae3a38a
2018-01-22 18:06:39 +08:00
jeremy.zhang
6892dd6047 Fix api-ref for v3 volume group types
This patch is mainly to fix api-ref for v3 volume group types,
including:

1. add description and example for the API: show defaut group type
2. fix parameters: 'is_public' and 'description'
3. remove unused sample file: group-type-show-request.json

Change-Id: I29f160d8ed24473debb345b4ea91ee0545d711b1
2018-01-18 08:56:17 +00:00
jeremy.zhang
0d371e98bb Fix api-ref for v3 volume types
This patch dome some fixs on api-ref for v3 volume types, including:

1. add api-ref and sample file for show default volume type API
2. remove unused sample file: volume-type-show-request.json
3. fix parameters: 'name', 'extra_specs', 'is_public', 'description',
and 'os-volume-type-access:is_public'

Change-Id: I6fdcb66d3a56643a5e71bcd68f4bcdc08fc4866b
2018-01-17 17:27:26 +08:00
Zuul
f7a62652f4 Merge "Remove skip_validation_flag to False by default" 2017-12-18 21:54:25 +00:00