Currently, the guess auth version in freezer client
is not correct, because opts.os_identity_api_version
has never been initialized. This patch will fix it.
Change-Id: Ie5ff077213956a48dcd13c75b6855be7402d253c
Closes-Bug: #1715539
Freezer client now has the ability to talk to v2 api endpoint
if you are using BaaS please use:
OS_BACKUP_API_VERSION=2
otherwise
OS_BACKUP_API_VERSION=1
Change-Id: I93715e18f96c35b7952f3aeac3cb05b56313f9a9
Currently, execute command 'freezer client-delete' to
delete a client will be failed with error "Namespace
object has no attribute 'client_uuid'", this patch
will fix it.
Change-Id: Ia2b56643c528327711e162e9e15b65ab1cf357bb
Closes-Bug: #1677572
What's new:
* while running client-list and client-show, uuid is getting none
modified the code to get correct uuid.
Change-Id: I629cdb1bb4bbabdd7e74b86f949cec44fb40e984
Closes-Bug: #1676264
Since backup_id is UUID in freezer-api, there is need to change some methods:
1. Removed workaround to get backup data and use standart API call get()
2. Fixed backup-list and backup-show output according to new backup structure
3. Added backup-delete feature based on backup_id query
Change-Id: I62f312ec3a0a56f5f2e6f8915023b34f87fa42de
Closes-Bug: #1646575
Closes-Bug: #1642151
Depends-On: I50ae24b11b58bcea3d2c9f117957300a926cd3ab
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
This patch adds almost full pep8 check including unit test code.
All code style problems is solved.
Change-Id: Ie9b31b2ecfafc22fc299d749ca45ce69fdc64472
Closes-Bug: #1645342
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Executing freezer action-create, job-create or session-create without
--file parameter causes NoneType error. The --file parameter should be
changed to required.
Change-Id: I7dcbe4ff2109d4ca1bac79604c918f79f522daa8
Closes-Bug: #1642126
Executing freezer session-add-job or session-remove-job without
any parameter causes error. The --session-id and --job-id parameter
should be changed to required.
Change-Id: Ie2e1d058526fd6a219be0179b8311f38ed16ef72
Closes-Bug: #1642130
Added session-delete action, for unknown reasons it was missed.
Change-Id: I45070e90cbdc366d3f1264b24e0a329532e5ff99
Closes-Bug: #1641993
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
List of improvements:
* Fixed bug with freezer complete command. The root cause of
this problem was not implemented methods get_parser in
classes SessionStart and SessionDelete.
* Actions session-start and session-end and appropriate classes
was removed due to this actions are not called by user, it's
triggered by freezer-scheduler directly [1].
* Action session-list now prints empty table if no sessions
found.
* Import objects replaced on import modules
[1]85ab97121e/freezer/scheduler/scheduler_job.py (L432)
Change-Id: I49933fd77d858fa0e07849889678de9703a4824e
Closes-Bug: #1640761
Closes-Bug: #1641991
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
When the list is empty, the different style output is being used for
the freezer action-list, backup-list, job-list, session-list and
client-list.
Achieve a consistent style output for these commands in this patch.
Change-Id: I17f65fc3a836357f2c4857b4e5f7de7c8e8fb116
Closes-Bug: #1642101
What's new:
* Print empty table if no clients found
* Check that client exists before delete,
print message if no clients with ID was found
* Import objects replaced by modules
* Some code refactored
Change-Id: I076afbcda21b1f1ca7a85d733f7fc7204487b25e
Closes-Bug: #1641184
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
Executing freezer client-register without --file parameter
causes NoneType error during open file. This patch fixes it
by changing --file parameter to required.
Change-Id: I3cd6112187aa6c2a5dee2489078968b04567f4a9
Closes-Bug: #1634766
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
There is a problem with executing CLI commands:
no endpoint type was provided during creating keystone
client object. This patch fixes it.
Also, there are some small changes:
* moving from keystoneclient to keystoneauth1
* fixed import order, replaced import objects
* supressed output from requests lib due to info messages in output
(Starting new HTTP connection (1))
Change-Id: I57c42877c94d6d5706a7b6bf1e154f29704f9783
Signed-off-by: Ruslan Aliev <raliev@mirantis.com>
As per OpenStack Docstrings guide lines [1]:
[H401] Docstrings should not start with a space.
[H403] Multi line docstrings should end on a new line.
[H404] Multi line docstrings should start without a leading new line.
[H405] Multi line docstrings should start with a one line summary
followed by an empty line.
[1] http://docs.openstack.org/developer/hacking/#docstrings
trivialfix
Change-Id: Ifbc123eec81f47f833f93e5a51f34e385767162e
We need to support sending accept to make sure the returning response
will be json formated. This is needed as we interact with different
Openstack components which support xml, json format and default is xml
Change-Id: I07db838de4aa6c50b357a5ca32e0a1ecc41c720b
Implements: blueprint python-freezerclient-to-accept-json-header