Commit Graph

23 Commits

Author SHA1 Message Date
Kendall Nelson 353f75eca0 Retire Karbor
As announced on the openstack-discuss ML[1], Karbor is retiring
this cycle (Wallaby).

This commit retires this repository as per the process defined in
the project-guide[2].

Thank you to all the contributors of Karbor for your hard work!

[1] http://lists.openstack.org/pipermail/openstack-discuss/2020-November/018643.html
[2] https://docs.openstack.org/project-team-guide/repository.html#retiring-a-repository

Depends-On: https://review.opendev.org/c/openstack/project-config/+/767030
Change-Id: I972ffb299f93863c4e34b1f504b002095661e6af
2020-12-21 11:51:02 -08:00
Sean McGinnis 3df667582c
Use unittest.mock instead of third party mock
Now that we no longer support py27, we can use the standard library
unittest.mock module instead of the third party mock lib.

Change-Id: Ifd0d1b8aa419e39361e76a4f846cb4eeaf0d46ca
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2020-08-13 08:28:07 -05:00
Zuul 3676e53e1b Merge "Fix bug for running unittest with unittest module" 2019-11-14 10:38:56 +00:00
wangwei1 d56877b3fe Fix bug for running unittest with unittest module
When we run unittest with a way like:
python -m unittest2 <test_file>
then NoSuchOptError exception will raised

Change-Id: Ib0f9276c1b86ff7f2d1e401ddfae2bf4e920fa78
2019-11-14 17:02:49 +08:00
shenxindi d1052b68eb Fix unit test error
Fix the order of decorators and parameters for
karbor.protection.manager.ProtectionServiceTest in unittest.

Change-Id: I9d58c33787e0b2039a046ea30c7238485a76af2d
2019-11-14 16:58:24 +08:00
jiaopengju ecc6b64f4a Add support to reset checkpoint state
Now when doing checkpoint copy failed, checkpoint
will be wait_copying status forever, and so we can
not do the restore anymore. So we should add an API
to support checkpoint status reset if we deeply knows
that the checkpoint is ok. This patch added API
support for doing checkpoint state reset.
Implements: bp checkpoint-status-reset

Change-Id: Iabaa98c9900fba554be2ad0833d438901e01147a
2018-12-03 14:02:01 +08:00
jiaopengju 37c197851a Add permission check when creating restore
Currently, general users have rights to restore other users'
checkpoints. We should add permission check to avoid the security
risk.
Closes-Bug: #1805004

Change-Id: If0f957a3aa8f25778833d7611342fab6b8efa388
2018-11-25 21:09:11 +08:00
jiaopengju b6342feeb6 Add project id support for checkpoints filter
Change-Id: I93ab8a3a503045fb8a7612cf47bbfa014ac00fd2
2018-11-21 17:58:49 +08:00
jiaopengju fde94b28e3 Add tenant isolation of checkpoints
Change-Id: Iaae21b4c7339f6453c391cb958fb828694b083fd
Implements: blueprint checkpoint-tenant-isolation
2017-10-20 09:22:38 +08:00
Jenkins 653d55d7c2 Merge "Fix NoneType error when got non-exist instance of protectable." 2017-09-26 01:40:15 +00:00
chenying 892f96c9a6 Add pod to the parent resource types of volume protectable plugins
Change-Id: I3e3a76450ba91e9b04400841b13a23efcbd5cca2
Implements: blueprint kubernetes-pods-protection-plugin
2017-09-19 14:33:28 +08:00
ericxiett 1f364aefa4 Fix NoneType error when got non-exist instance of protectable.
When calling show_resource() in protection.manager.ProtectionManager,
the result may be None that got the NoneType has no attribute
 'to_dict'. This patch fixes it.

Change-Id: I895fa492acbac8885cfb27640528280b69ba7c14
Closes-Bug: #1716860
2017-09-14 18:54:20 +08:00
jiaopengju 0c042063b6 Remove network dependency of server resource
Currently, network topology is the dependency of server
resource, it will make users confused to protect the server
with network topology and bring network conflict issues.

This patch will fix it.

Change-Id: I21d62d66f5d66a1bc5e2c41ffc510fba19393ac5
Closes-Bug:#1711879
2017-08-29 15:49:22 +08:00
chenying 919333722a Add operation_log API for karbor
This API is a new one. After this API is merged to karborclient.
I will submit another patch about fullstack of it.

Change-Id: Idf67d5fdc5c2c4bb960212dae4c18294109a6fbf
blueprint: operation-log-api
2017-07-27 10:12:20 +08:00
sudhir_agarwal fa132e33b1 Fixed order of arguments in assertEqual
Some tests used incorrect order of arguments in
assertEqual(observed, expected). The correct order expected
by testtool is assertEqual(expected, observed).

Change-Id: I2f5d59b1115c82c2811aeb753404ac2c99d2746d
2017-07-14 11:56:41 +00:00
chenhuayi2 5f5680fcb2 Implement neutron network protectable plugin
Closes-Bug: 1569998

Change-Id: Ie99bb1e7a6ba9e70e1f65ab7b252827cf783e6c5
2017-06-20 14:21:14 +08:00
Jenkins 701d424edc Merge "Remove unused logging import" 2017-05-09 02:04:06 +00:00
chenying b769957149 Add extra_info field to the response of instances API
User can get the extra_info of resource instances from
the response of this API.

Co-authored-by: xiangxinyong <xiangxinyong@huawei.com>

blueprint instances-extra-info
Change-Id: Id97b8e5b3c29283320f5d4aa81d3947505b35671
2017-03-30 22:55:42 +08:00
Yuval Brik 24e0ef24ad client_factory, keystone plugin: lazy init
Change-Id: I0aeddb50fea40d2ce6fd4b7abc9a759b6898e92f
2017-03-09 04:26:09 +08:00
Anh Tran 00f1e914f5 Remove unused logging import
Change-Id: I244831169ade59cbb614220234096f4fe7237847
2017-02-17 10:17:45 +07:00
zengchen 6386bf5bf5 Prepare for refactoring clients used in protect service
This patch has done the preparation works for refactoring clients,
such as initiate keystone plugin, generate session etc. There are
several patches to do for refactoring the clients.

Change-Id: I61d2a42fb6f0de2d98714a7e19c1a220dec95082
Implements: blueprint refactor-clients
Partial-Bug: #1566793
2017-01-22 11:56:49 +08:00
Yuval Brik a80b9cc283 Stabilize Protection Plugin API
Protection plugin now needs to implement methods for each operation
(protect, delete, restore). Each protection plugin is created in the
context of the flow, while each operation is created in the context of
the resource.

A protection plugin is responsible for returning an Operation class for
each operation. Such Operation class defines the behavior of the
protection plugin by implementing these optional hooks:

- on_prepare_begin hook is invoked before any hook of this resource and
  dependent resources has begun
- on_prepare_finish hook is invoked after any prepare hooks of dependent
  resources are complete.
- on_main hook is invoked after the resource prepare hooks are complete
- on_complete hook is invoked once the resource's main hook is
  complete, and the dependent resources' on_complete hooks are complete

HeatTemplate is now created and supplied from a task instead of being
created and passed to resource tasks before the restore operation began.

Change-Id: I847eec6990b2d24a66a12542d242fbfb682272fe
Co-Authored-By: Saggi Mizrahi <saggi.mizrahi@huawei.com>
Implements: blueprint protection-plugin-is-design
2016-12-19 15:09:55 +02:00
chenying 1c60dac7fa Change Smaug to Karbor
There was a decision in the community to change the project name.

Change-Id: I8b3d538b9573ebaa2a873f4696e1f1a500c941a8
2016-08-18 22:55:34 +08:00