Commit 59824da
committed
Fix talking to older servers
Cinderclient currently supports version 3.71 as defined in
`cinderclient.api_versions.MAX_VERSION`. When doing version discovery,
we create a temporary client with the MAX_VERSION and use this client to
fetch the available versions. If the server doesn't support 3.71, yet,
the version discovery request fails with:
cinderclient.exceptions.NotAcceptable: Version 3.71 is not supported by the API. Minimum is 3.0 and maximum is 3.70. (HTTP 406)
ERROR: Version 3.71 is not supported by the API. Minimum is 3.0 and maximum is 3.70. (HTTP 406)
To fix this, we instead create a client with the MIN_VERSION, because
the versions endpoint should be available there already.
NOTE: Even when specifying an `--os-volume-api-version 3.70` the request
fails, because version discovery still takes place in case we have to
downgrade from the requested version.
Change-Id: I38b71cea6b92da7f451e2a02d55900fe18e9aab0
Signed-off-by: Johannes Kulik <johannes.kulik@sap.com>
Closes-Bug: #19985961 parent 018955c commit 59824da
2 files changed
Lines changed: 10 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
771 | 771 | | |
772 | 772 | | |
773 | 773 | | |
774 | | - | |
| 774 | + | |
775 | 775 | | |
776 | 776 | | |
777 | 777 | | |
778 | | - | |
| 778 | + | |
779 | 779 | | |
780 | 780 | | |
781 | 781 | | |
| |||
840 | 840 | | |
841 | 841 | | |
842 | 842 | | |
843 | | - | |
| 843 | + | |
844 | 844 | | |
845 | | - | |
| 845 | + | |
846 | 846 | | |
847 | 847 | | |
848 | 848 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
0 commit comments