Sync latest apiclient code from Oslo

We needs to update apiclient code to have ability to use it in py3 environment.

Сhanges from oslo-incubator related to apiclient
=====================================================================
Change 8575d87 - Removed copyright from empty files
Change bbaf317 - Use encode() instead of strutils.safe_encode() in fake_client
Change 41dc2b4 - Encode response from FakeHTTPClient
Change e6494c2 - Use six.iteritems to make dict work on Python2/3
Change 0d8f18b - Use urlutils functions instead of urllib/urllib2
Change 16fb43b - Replace data structures' attribute with six module
Change 9d0ec6a - Use six.iteritems for python 3.3 support in apiclient module
Change 12bcdb7 - Remove vim header
Change 4c22556 - Use py3kcompat urlutils functions instead of urlparse
Change 3970d46 - Fix typos in oslo
Change 1771a77 - Adjust import order according to PEP8 imports rule
Change da611e6 - Transform the for loop to expression
Change 4bfb7a2 - Apply six for metaclass
Change eca62f7 - Changed header from LLC to Foundation based on trademark policies

Change-Id: Ia87807828f344e463fa308413bd627dc57d1a41d
Add auth_plugin support to cinderclient

With CINDER_RAX_AUTH being rightfully removed, cinderclient is no longer
compatible with Rackspace/any non-keystone auth. To fix this, I stole
auth_system/auth_plugin from novaclient's implementation.

See https://review.openstack.org/#/c/23820/.

Change-Id: If5f84003f868ef02bb7eb7da67cf62018602e8f0
Closes-Bug: 1280393
Wrong hint key in volume create function

Hint key has to be 'OS-SCH-HNT:scheduler_hints' not 'scheduler_hints'
and scheduler_hints key has to be located in same level with volume.

Change-Id: Ic5888545d4b7ee6bb58a22840928ef1fc86fedfa
Closes-Bug: #1276088
Allow list_extensions to work in cinderclient v2

Cinder client extensions also requires explicity setting the
service_type that they are available for. This makes the only extension
for the client available to v2 as well.

Change-Id: I9a73cac31c70b248ac6070540554f9293e9a6e43
Closes-Bug: #1284321
When there is no error body return the HTTP reason

Return the response reason when there is no message body to return.

DocImpact
Change-Id: Ia60da4f04b059a13fcbe0059bb42fd77f272d8aa
Closes-Bug: 1248773
replace assertTrue(isinstance) to assertIsInstance

some of tests use different method of assertTrue(isinstance(A, B))
or assertEqual(type(A), B). The correct way is to use
assertIsInstance(A, B) provided by testtools

Change-Id: Ic3eb7b27dc96b0ec7d786c092fc3a6a513af64f7
Closes-bug: #1268480
Fix usage of v1 and v2 availability zones

Change usage of availability zones in client. V2 client should
use appropriate version of manager of availability zones.

Also change tests of v2 availability zones to test version 2
instead of one more time test v1 availability zones.

Change-Id: Iec3863a105a20f876a303f789cc1edfafa58f4df
Closes-Bug: #1290956
CLI for disable service reason

Adds cli option to allow users to give reason
for service-disable. Also adds disabled reason
as a column in service list, so any disabled service
can be seen with reason.

A recent cinder change that allows disable-log-reason
allows users to provide reason for disabling service.
This just adds the cli option for the method.

Implements bp record-reason-for-disabling-service

Change-Id: I90f4566764790eeb0c047c4a0fd0108050ab6ad9
Merge "Allow list_extensions to work in cinderclient v2"
Include the Python 3/3.3 trove classifiers

These are often used by automated tools to check for Python 3 support.

Change-Id: I29fae2c0b80d28a865cc0972272e470da720ca11
Updated from global requirements

Change-Id: Icc67410c32244a1b1dfb6484acf4581c53e47fb5
Add quota-delete command to cinder client

Add the command quota-delete <tenant_id> to the client.

This change depends on the cinder change:
Ia040a20abb831c311eb13624ddecbbf0f12fdd9f

DocImpact

Implements blueprint quota-delete
Change-Id: I1e5c98154dc3c6de168747eb912b45265cd1b9db
Accept deleting multiple snapshots in one shot

In bug 1241941 the delete and force-delete commands were updated to
accept multiple volumes for deleting in the same call. This patch adds
the same behaviour to the snapshot-delete command.

Closes-Bug: #1284540
Change-Id: I5e4bf8641d7fd261fa24b03832bad08007e43c12
Merge "replace assertTrue(isinstance) to assertIsInstance"
Merge "CLI for disable service reason"
Merge "Sync latest apiclient code from Oslo"
Merge "Wrong hint key in volume create function"
Merge "Include the Python 3/3.3 trove classifiers"
Fix malformed encryption-type body in test cases

This change addresses bug #1286261 and fixes two malformed
encryption-type bodies in two test_create test cases.

Change-Id: I308561c1d5a70812889a93922e13194597f670f1
Closes-Bug: #1286261
Ambiguous option error should not appear if Arg is SUPPRESS

Due to backward compatibility there are arguments hidden.
For example:

--tenant-id and --tenant_id

On those case the abbreviation mechanism if a user enter
--tenant throw that there is an ambiguity but the helps only
show --tenant-id as an optional argument.
This change remove this ambiguity if one of them is hidden.

Change-Id: I413f1ebafc68b3e02b5abadce1608e6d48207b01
Closes-Bug: #1252457