python3: sort dict for post_volumes_1234_action test

In Python 3, hash randomization is enabled by default. It causes the
iteration order of dicts and sets to be unpredictable and differ across
Python runs.

Sort the list and update the expecting result.

Change-Id: Iead7ca8f45b035abd78f0b25865b5f7e1b9f3294
Signed-off-by: Chuck Short <chuck.short@canonical.com>
python3: align the order of parameters for urlencode()

In Python 3.3, hash randomization is enabled by default. It causes the
iteration order of dicts and sets to be unpredictable and differ across
Python runs.

In the test case, the fixed expecting string will not match the test
result, it is relying on the dict order.

This change transforms the input dict to a sequence of two-element list,
with fixed order, and update the related expecitng string in test case.

Change-Id: I60d7bb3c4f940b76460ad5c417a1807915e0418e
Signed-off-by: Chuck Short <chuck.short@canonical.com>
Addition of volume/snapshot_metadata CLI

Added below CLIs:-
1. Set or Delete metadata of a snapshot
2. Show metadata of a snapshot
3. Show metadata of a volume
4. Update all metadata of volume
5. Update all metadata of snapshot

Implements blueprint: add-metadata-cli

Change-Id: Ic2b5f3fce6104d1756879718f666a42549458ad3
Deprecates --volume-id arg for v2 backup-restore

This patch deprecates the --volume-id arg of backup-restore
when using the v2 api and adds (preferred) --volume arg.
Both args are still usable but the former is now listed as
"Deprecated" in the help message.

Change-Id: I2575d93041b26f971c59bc04828b356556617b62
Fixes: bug 1242816
Merge "python3: align the order of parameters for urlencode()"
Merge "python3: sort dict for post_volumes_1234_action test"
Adding Read-Only volume attaching support to Cinder client

Adding mode argument to volume manager attach function.
Allow Nova using read-write or read-only mode to attach a volume to an
instance.

blueprint read-only-volumes

Change-Id: Ib20c7802304d83f4aafef522171ebd47f672d883
Signed-off-by: Zhi Yan Liu <zhiyanl@cn.ibm.com>
Enable "cinder delete" can delete multiple volumes in one request

"nova delete" can delete multiple servers in one request but
"cinder delete" can only delete one volume in one request, it is
better to enhance cinder client to support remove multiple volumes
in one request.

Change-Id: I6a63aa3d7e4c152ae5e45bf2b36d862bdcd6df33
Closes-Bug: #1241941
Merge "Addition of volume/snapshot_metadata CLI"
Adding volume readonly-mode-update interface to Cinder client

Adding volume readonly-mode-update interface to shell and client object
(v1 and v2) to allow end user update volume read-only access mode flag.

blueprint read-only-volumes

Related-Id: I4c84614d6541d5f7c358abadb957da7b8c3d9c48
Change-Id: I2d587f301a21c0d42b8940465862da25a70ed5a8
Signed-off-by: Zhi Yan Liu <zhiyanl@cn.ibm.com>
Merge "Adding volume readonly-mode-update interface to Cinder client"
Enable del of other tenants resources by name

Currently, due to the way that resources are being retrieved by the
findall() function, an administrator can do a list, snapshot-list, etc.
with the --all_tenants option and see other tenants' resources.  If the
admin then tries to delete the another tenants' resource by name, it fails
with a 'No <resource> with a name or ID of <name> exists.' error.

The solution to this is to change the call to the list() function in
findall() to set the all_tenants search option to 1.  This causes the
admin to get a list of all the resources that they have access to back
when the search is done instead of just a list of their resources.  The
delete by name is then possible.  The server takes care of ensuring that
only resources that the user has access to are returned.

This will enable delete by name for all resources that use the find_resource
function.

Closes-bug: 1241682
Change-Id: I4e9957b66c11b7e1081f066d189cedc5a3cb2a6c
Fix py33 due to readonly and metadata patches

A couple recent merges broke py33 - this fixes it.

Change-Id: Iaab8a08aeb42c954f3ecff7da70003d1c4eead0d
Merge "Enable del of other tenants resources by name"
Update version and index.rst for push

Update prior to push 1.0.7 to PyPi.

Includes changes/updates to doc/source/index and
adds link to README.rst

Change-Id: I666f3e6004885db7a688abdac88fa1154d83f8c9