summaryrefslogtreecommitdiff
path: root/cinderclient
Commit message (Collapse)AuthorAgeFilesLines
* Merge "Remove promote/reenable replication"Zuul2019-07-105-71/+0
|\
| * Remove promote/reenable replicationMinmin Ren2019-06-195-71/+0
| | | | | | | | | | | | | | | | | | | | The replication 1.0 API os-promote-replica and os-reenable-replica were removed[1], then remove useless code from cinderclient. [1]: https://review.openstack.org/#/c/275797/ Change-Id: Icf98f294c089942e11607786e932abc959f77b3b
* | Add missed 'Server ID' output in attachment-listMinmin Ren2019-06-043-9/+31
|/ | | | | | | | | | | | | | | | | | | 'server_id' is not Attachment attribute, should be set by 'instance' attribute. v3/attachments respond body: {"attachments": [{"status": "attached", "instance": INSTANCE_UUID, "id": ATTACHMENT_UUID, "volume_id": VOLUME_UUID, }, ... ] } Change-Id: Ica5d278cb7455befe1db4be0ab65114fd606ea0a
* Merge "Add bash completion for groups"Zuul2019-06-031-0/+25
|\
| * Add bash completion for groupsEric Harney2019-03-071-0/+25
| | | | | | | | | | | | Completion for group create/list. Change-Id: I0b7027a72a3bc8ad7ca7323c6dbe0a501616cdd5
* | Merge "Fix shell upload-to-image with no volume type"Zuul2019-05-235-18/+51
|\ \
| * | Fix shell upload-to-image with no volume typeEric Harney2019-04-035-18/+51
| | | | | | | | | | | | | | | | | | | | | | | | Upload-to-image would error after launching the operation if the volume type is None. Closes-Bug: #1821818 Change-Id: I015e0ddfa98d62f25334e2df5effaee72a3988ab
* | | Merge "Correct discover_version response"Zuul2019-05-042-9/+27
|\ \ \
| * | | Correct discover_version responseBrian Rosmaita2019-04-252-9/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The discover_version function was ignoring the max microversion supported by the client. This patch corrects its behavior to return the most recent API version, if any, supported by both the client and the server it is communicating with. Closes-bug: #1826286 Change-Id: If22b72452065080b24cb1b899c5a5a88b809e986
* | | | Merge "Remove bash-completion calls from base.py"Zuul2019-04-261-9/+3
|\ \ \ \ | |/ / / |/| | |
| * | | Remove bash-completion calls from base.pyEric Harney2019-04-021-9/+3
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | This should not be here since this is client library code, but it isn't needed anyhow since this completion is handled from the shell code. Closes-Bug: #1817782 Change-Id: I3e7ddbe4a50a66db8961a71d71592ce708320b0d
* | | Merge "Handle auth redirects"Zuul2019-04-222-9/+31
|\ \ \
| * | | Handle auth redirectsSean McGinnis2019-04-182-9/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Our checking for keystone v2 and v3 was causing v2 tests to go down the v1 code path. Fixing this surfaced a couple of long standing issues with our v2/v3 handling of redirects and getting auth info. This fixes our version identification, fixes extracting redirect location for response headers, and returning the auth_url to calling code. Change-Id: I939ff027bf43e513e338bff1e99ca41fa52637b6 Closes-bug: #1825372 Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* | | | Raise API max version for Stein updatesSean McGinnis2019-04-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Functionality was added during stein, but the MAX_VERSION of the client was not updated for these versions. This raises the version to support the added functionality. 3.57 - Improve volume transfer records - no client changes 3.58 - Add project_id to group - no client changes 3.59 is not included here as that adds sort and pagination that will need to be slightly reworked before we expose it. Change-Id: If8a3b88b9a2811ae6681e52dbca62b906d3542eb Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* | | | Add support for backup user IDSean McGinnis2019-04-172-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Backup user_id was added with microversion 3.56 but never added to the client. Added in Rocky with I3ffb544ef3ee65276cee8b1e870d524fd0e57085. Change-Id: Ib9a4159db0f8af599dcf8315334de4f859be077e Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* | | | Raise API max version for Rocky updatesSean McGinnis2019-04-171-1/+1
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Functionality was added during rocky, but the MAX_VERSION of the client was not updated for these versions. This raises the version to support the added functionality. 3.53 - Schema validation - no client changes 3.54 - Add mode option to attachment-create: I22cfddd0192c4a72b8f844f23d1fa51b96c57e06 3.55 - Transfer snapshots with volumes I61a84b5abf386a4073baea57d8820c8fd762ae03 Change-Id: I8c8fb8f552e529c8474a3e3b771ba8eb7aed193a Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* | | Merge "Tests: Don't write bash-completion cache files"Zuul2019-04-026-0/+33
|\ \ \ | |/ / | | / | |/ |/|
| * Tests: Don't write bash-completion cache filesEric Harney2019-02-266-0/+33
| | | | | | | | | | | | | | | | | | Mock out writing of bash-completion cache files during unit tests. Related-Bug: #1817782 Change-Id: I944862c30fb4684dd034eba6953e9302d2d22439
* | Merge "Fix: cinder group-list not working with non-admin user"Zuul2019-02-252-13/+11
|\ \
| * | Fix: cinder group-list not working with non-admin userwhoami-rajat2019-02-182-13/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The all_tenants filter is passed to API when it's value is 0 (when not specified) which shouldn't be the case. This patch only allows adding of all_tenants when specified manually by user. Change-Id: Ic7810c4d6e9f4be7c28c7a8778d57bb5ccb996a0 Closes-Bug: #1808621 Closes-Bug: #1808622
* | | Merge "Change bash completion dir permissions to 0750"Zuul2019-02-151-1/+1
|\ \ \ | |_|/ |/| |
| * | Change bash completion dir permissions to 0750Eric Harney2018-12-051-1/+1
| | | | | | | | | | | | | | | | | | This is no reason for this dir to be world-readable. Change-Id: I50e85b5bb6116c64535ecbf09718141086c703c5
* | | Fix max version handling for help outputSean McGinnis2019-01-302-2/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit fefe331f218d73ba6d1d7acf81b5eb02609c953e incorrectly set the default API version to the max the client knew about in order to get the full help output, including all microversioned commands. The original intent was to have help print out information for all versions, but still require the user to specify a version if they wanted to use any microversioned version of an API. The code accidentally made it so all commands would request the max version the client knew about. This meant an unspecified request would get the newer functionality rather than the default v3 functionality, and also meant the client could request a microversion higher than what the server knew about, resulting in an unexpected error being returned. To keep the originally intended functionality, but keep all help output, this only uses the max API version for the help command unless the user specifies otherwise. Closes-bug: #1813967 Change-Id: I20f6c5471ffefe5524a4d48c967e2e8db53233f1 Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* | | Merge "Remove i18n.enable_lazy() translation"Zuul2019-01-301-5/+0
|\ \ \
| * | | Remove i18n.enable_lazy() translationSean McGinnis2018-11-131-5/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Per [1], don't. [1] http://lists.openstack.org/pipermail/openstack-dev/2018-November/136289.html Change-Id: I4a1e8cf84a88e5bd301d1baba41b064cde336f38 Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* | | | Fix incorrect punctuationyenai2019-01-281-3/+3
| | | | | | | | | | | | | | | | Change-Id: I70e1ad2d0152e74ab0672a3ac2e7b47f85ee92d7
* | | | More shell completion cache additionsEric Harney2018-12-212-1/+44
| |_|/ |/| | | | | | | | | | | Closes-Bug: #1712835 Change-Id: I9326d5d92ff2e93dd0398d9a115210b376059064
* | | Re-enable shell UUID completion cacheEric Harney2018-12-141-0/+25
| |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This enables writing ids to a local completion cache when using the cinderclient shell, which allows tools/cinder.bash_completion to complete commands such as cinder delete a<tab> Volume ids are recorded on "cinder list" and "cinder create" operations, similar for backup ids. This functionality was unintentionally removed in changes some time ago. Labeled as Partial-Bug because I haven't added name caching yet, which also used to exist. Partial-Bug: #1712835 Change-Id: Id56aa43b061758a00a2a8c9c92a5a33ab9f7ab84 (cherry picked from commit c4b37c2830fdd90b57383a93e09a8bd40ca41221)
* | Change cache uniqifier from using md5 to sha-1Joshua Cornutt2018-12-051-3/+3
|/ | | | | | | | | | FIPS 140-2 does not allow MD5 use for most purposes and systems in "FIPS mode" (fips=1 kernel flag) will cause software using MD5 from popular libraries to fail. Also change the default cache dir to use ~/.cache/ Change-Id: I6f653f10249992196abb04e05c54df5fb244b182
* Merge "Replace assertRaisesRegexp with assertRaisesRegex"Zuul2018-11-102-10/+10
|\
| * Replace assertRaisesRegexp with assertRaisesRegexzhangyangyang2018-08-292-10/+10
| | | | | | | | | | | | | | This replaces the deprecated (in python 3.2) unittest.TestCase method assertRaisesRegexp() with assertRaisesRegex(). Change-Id: I85025ad141f8436913ba192716435ce63e1e2d05
* | Fix incorrect use of flake8:noqaSean McGinnis2018-10-2613-17/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adding the comment flake8:noqa in a file will skip linting the entire file. Most of the time, the intent was just to skip individual lines to handle exception cases. This gets rid of the "flake8:" prefix where it was used incorrectly and fixes a few legitimate errors that were being hidden by the entire file being skipped. The behavior is change in flake8 to handle this better, which will result in pep8 job failures if these are not fixes first. See more information in the 3.6.0 release notes: http://flake8.pycqa.org/en/latest/release-notes/3.6.0.html#features Change-Id: I56cb20a7c8885c101826d4fe28c315de02b6ecb8 Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* | Merge "Fix encoding of query parameters"4.1.0Zuul2018-10-0312-60/+65
|\ \
| * | Fix encoding of query parametersGoutham Pacha Ravi2018-09-1312-60/+65
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | IETF RFC 3986 classifies "~" as a reserved character [1], however until python3.7 [2], python's url parsing used to encode this character. urllib has seen a lot of churn in various python releases, and hence we were using a six wrapper to shield ourselves, however, this backwards-incompatible change in encoding norms forces us to deal with the problem at our end. Cinder's API accepts "~" in both, its encoded or un-encoded forms. So, let's stop encoding it within cinderclient, regardless of the version of python running it. Also fix an inconsitency around the use of the generic helper method in utils added in I3a3ae90cc6011d1aa0cc39db4329d9bc08801904 (cinderclient/utils.py - build_query_param) to allow for False as a value in the query. [1] https://tools.ietf.org/html/rfc3986.html [2] https://docs.python.org/3/library/urllib.parse.html#url-quoting Change-Id: I89809694ac3e4081ce83fd4f788f9355d6772f59 Closes-Bug: #1784728
* | Merge "refactor the getid method base.py"Zuul2018-10-032-13/+5
|\ \
| * | refactor the getid method base.pyzhubx0072018-08-082-13/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Refer to a merged commit. https://review.openstack.org/#/c/588983/ Refactor the getid method both in cinderclient/base.py and in cinderclient/apiclient/base.py TrivialFix Change-Id: I4d1fb81f6876ab072ded3f14004ad064dcc949d3
* | | Merge "Fix backwards compat for volume transfer < 3.55"Zuul2018-10-023-31/+128
|\ \ \
| * | | Fix backwards compat for volume transfer < 3.55Sean McGinnis2018-08-043-31/+128
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | All volume transfer v3 calls were being sent to the endpoint introduced with microversion 3.55. This fixes backwards compatibility by routing calls less than 3.55 to the original API extension endpoint. Change-Id: I7205033ddd5be126b8614372a9fc82a2bc555f48 Closes-bug: #1785330 Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* | | Merge "Fix functional error check for invalid volume create size"Zuul2018-10-021-2/+2
|\ \ \
| * | | Fix functional error check for invalid volume create sizeSean McGinnis2018-09-111-2/+2
| | |/ | |/| | | | | | | | | | | | | | | | | | | With the api-schema enforcement on the Cinder API side, the error message returned when specifying a volume creation of 0 has changed. This results in our functional tests failing. Change-Id: I1a9a13f683134faa01ad50f7f073db8b1845a901
* | | Merge "Fix endpoint identification for api-version query"Zuul2018-10-022-4/+21
|\ \ \
| * | | Fix endpoint identification for api-version querySean McGinnis2018-08-062-4/+21
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The api-version query is a GET against the root endpoint of cinder. Determining this root endpoint had a flaw with the newer wsgi deployment URLs that would cause it to find the root endpoint of the web server and not cinder. This updates the logic to work with legacy, wsgi, and custom URLs for the Cinder endpoint. Change-Id: Iaeba1f8d50ee8cc9410cc9f638770a56796871fb Closes-bug: #1785594 Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* | | Merge "Default help output to include MV updates"Zuul2018-10-021-2/+1
|\ \ \
| * | | Default help output to include MV updatesSean McGinnis2018-09-201-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We are inconsistent with some other projects with hiding client help output for commands added with microversions by default. This often leads to confusion with users of the CLI not being aware of these changes. This changes the default to display all help output. Users can still specify a version and have the output limited to include only options up to the version they specify. Change-Id: I39d90a1ecc824fcf445e98609de47d45e71a0ff6 Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* | | | Merge "[Optimize] Update help text for hint argument"Zuul2018-10-012-2/+6
|\ \ \ \ | |/ / / |/| | |
| * | | [Optimize] Update help text for hint argumentTommyLike2018-07-172-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Update scheduler_hint's help text to describe how to specify multiple hints and array value. Change-Id: If975e06b6e9914848498fa2c3ab27c2f41d7860b
* | | | [Trivial] Add backup-id to 'size' param infowhoami-rajat2018-09-191-1/+1
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | Specifying size is not required while providing --backup-id. Also When we don't provide the size the output turns out to be error: Size is a required parameter if snapshot or source volume or backup is not specified. which should be modified in 'size' info too. Change-Id: Ia250df37db9170757d5f834d516781e04582f08b
* | | __repr__ crashes when empty dict passedwhoami-rajat2018-08-132-1/+6
| |/ |/| | | | | | | | | | | | | | | | | The Capabilities class __repr__ method crashes when along with any manager object, the info is passed as empty dict. This patch handles the issue. Change-Id: Ife5cfc82137d107b27b011aa83c3a9c89e78d701 Closes-Bug: #1785091
* | Allow volume-transfer creation < 3.55 microversion4.0.1Sean McGinnis2018-07-313-63/+24
| | | | | | | | | | | | | | | | | | | | | | Handling for the new `no_snapshots` option was incorrectly handling microversion evaluation that would prevent anything less than the new microversion from working. This changes the check to only handle the changed argument for 3.55 and later. Change-Id: If96889ccde6044706e6a5dcd83fde3c20fe1c1fd Closes-bug: #1784703 Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
* | Merge "Reflect multiattach deprecation in help text"4.0.0Zuul2018-07-272-2/+2
|\ \